Use readlines, not read
This commit is contained in:
parent
545fd53b88
commit
4fa61ea14a
@ -14,7 +14,7 @@ require 'optparse'
|
|||||||
|
|
||||||
# Write usage message to stdout and exit.
|
# Write usage message to stdout and exit.
|
||||||
def usage(stream=$stderr, status=1)
|
def usage(stream=$stderr, status=1)
|
||||||
stream.puts File.read(__FILE__).
|
stream.puts File.readlines(__FILE__).
|
||||||
grep(/^#\//).
|
grep(/^#\//).
|
||||||
map { |line| line.sub(/^#. ?/, '') }.
|
map { |line| line.sub(/^#. ?/, '') }.
|
||||||
join
|
join
|
||||||
|
Loading…
Reference in New Issue
Block a user