home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / ruby164.zip / rbemx164.zip / ruby / share / doc / eruby-0.9.4 / examples / e2r.rb next >
Text File  |  2001-06-04  |  155b  |  10 lines

  1. require "eruby"
  2.  
  3. if filename = ARGV.shift
  4.   file = open(filename)
  5. else
  6.   file = STDIN
  7. end
  8. compiler = ERuby::Compiler.new
  9. print compiler.compile_file(file)
  10.