From: Zach Dennis Date: 2004-09-25T02:20:55+09:00 Subject: Re: Ruby Code to HTML A quick and dirty way might be: #!/usr/bin/ruby input = File.open( "file.rb" , "r" ) output = File.new( "file.html" , "w+" ) input.each_byte{ |c| case c.chr! when "\n" output.write( "
\n" ) when "\s" output.write( " " ) when "\t" output.write( 4.times{ "nbsp;" } ) else output.write( c ) end } Zach