Permalink
Browse files

Merge Ruby 1.9 fixes from evaryont/master

  • Loading branch information...
2 parents eed5d48 + c183785 commit 889fcb286bf0c2e93ec24f8a4f8fce881db3df7c @rtomayko rtomayko committed Apr 2, 2010
Showing with 3 additions and 3 deletions.
  1. +3 −3 bin/rocco
View
6 bin/rocco
@@ -14,7 +14,7 @@ require 'fileutils'
# Write usage message to stdout and exit.
def usage(stream=$stderr, status=1)
- stream.puts File.read(__FILE__).
+ stream.puts File.readlines(__FILE__).
grep(/^#\//).
map { |line| line.sub(/^#. ?/, '') }.
join
@@ -35,8 +35,8 @@ options = {}
ARGV.options { |o|
o.program_name = File.basename($0)
o.on("-o", "--output=DIR") { |dir| output_dir = dir }
- o.on("-l", "--language=LANG") { |lang| options[:language] = lang }
- o.on("-c", "--comment-chars=CHARS") { |chars| options[:comment_chars] = Regexp.escape(chars) }
+ o.on("-l", "--language=LANG") { |lang| options[:language] = lang }
+ o.on("-c", "--comment-chars=CHARS") { |chars| options[:comment_chars] = Regexp.escape(chars) }
o.on_tail("-h", "--help") { usage($stdout, 0) }
o.parse!
} or abort_with_note

0 comments on commit 889fcb2

Please sign in to comment.