1
0
Fork 0
mirror of https://github.com/pry/pry.git synced 2022-11-09 12:35:05 -05:00

unbreak pry executable

Options passed to pry executable, i.e '-h'  were not removed from ARGV
causing pry to attempt to open the "-h" file to load it through the REPL.

Fixed by removing flags from ARGV during option processing.
This commit is contained in:
John Mair 2012-06-20 14:14:37 +12:00
parent e2f817b460
commit 586ccfa50f

View file

@ -61,7 +61,7 @@ class Pry
self.input_args = args
opts = Slop.parse(args, :help => true, :multiple_switches => false, &options)
opts = Slop.parse!(args, :help => true, :multiple_switches => false, &options)
option_processors.each { |processor| processor.call(opts) } if option_processors # option processors are optional
self