Mar 31, 2008
Technomancy_small Phil Hagelberg 2 posts

Topic: Programming Ruby 3 / RDoc::usage removed in 1.9

Actually, it looks like the usage.rb file is still present in my Ruby 1.9 installation (but not in the source checkout, which is extremely odd.) However, it appears the usage of usage may have changed:

~/src $ ./showtime.rb --help
/usr/local/lib/ruby/1.9.0/rdoc/usage.rb:100:in `initialize': No such file or directory - ./showtime.rb:29:in `<main>' (Errno::ENOENT)
    from /usr/local/lib/ruby/1.9.0/rdoc/usage.rb:100:in `open'
    from /usr/local/lib/ruby/1.9.0/rdoc/usage.rb:100:in `usage_no_exit'
    from /usr/local/lib/ruby/1.9.0/rdoc/usage.rb:93:in `usage'
    from ./showtime.rb:29:in `rescue in <main>'
    from ./showtime.rb:29:in `<main>'

showtime.rb was copied from page 259 of the PDF.

 
Mar 31, 2008
Technomancy_small Phil Hagelberg 2 posts

Topic: Programming Ruby 3 / RDoc::usage removed in 1.9

On pages 258-260 of the Pickaxe 3 PDF, it talks about the RDoc::usage tool. I tried using it in Ruby 1.9, and it seems to be absent. It looks like it was removed, since it’s definitely in my Ruby 1.8 installation but missing in trunk. See: http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/trunk/lib/rdoc/

2 posts