Printing ruby code

L

lists

Hi,

What is the best way/tools to printing ruby code to a piece of paper
with:
1. method index
2. line number
3. syntax highlight
?.

Regards,


-- Zakaria
(e-mail address removed) Yahoo!: z4k4ri4
http://zakaria.is-a-geek.org
http://pemula.linux.or.id
Mau invite gmail? japri aja.

This is just off the top of my head, so it may not suit your needs
but here goes: If you happen to use Vim, you could convert the ruby
file to an html file with the :TOhtml command, then open the html
file in a web browser and print it. I'm sure that other text editors
can do something like this as well.

-Ryan
 
K

Ken Collins

This is just off the top of my head, so it may not suit your needs
but here goes: If you happen to use Vim, you could convert the
ruby file to an html file with the :TOhtml command, then open the
html file in a web browser and print it. I'm sure that other text
editors can do something like this as well.

That's kind of what I was going to recommend. I use a Drupal blog
with VIM perl modules installed in the blog and on my server to
syntax color code, ruby included.

- Ken
 
J

James H.

I can't quite help you with your question directly (I just print from
Textmate -- not colour coded), but for those of you looking to print
code in their Wordpress powered blogs, I've been using Code Snippet
(http://blog.enargi.com/codesnippet/). Although it doesn't officially
support Ruby, if you move Ruby script from the Geshi folder (a required
dependency) into your Code Snippet directory, you'll be made in the
shade.

James Herdman
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,014
Latest member
BiancaFix3

Latest Threads

Top