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

Upgrade slop syntax in cli.rb

This commit is contained in:
Conrad Irwin 2012-05-30 23:38:21 -07:00
parent ac93592f72
commit 03b047e6f8

View file

@ -78,7 +78,7 @@ See: `https://github.com/pry` for more information.
Copyright (c) 2011 John Mair (banisterfiend) Copyright (c) 2011 John Mair (banisterfiend)
-- --
} }
on :e, :exec, "A line of code to execute in context before the session starts", true on :e, :exec, "A line of code to execute in context before the session starts", :argument => true
on "no-pager", "Disable pager for long output" do on "no-pager", "Disable pager for long output" do
Pry.config.pager = false Pry.config.pager = false
@ -115,11 +115,11 @@ Copyright (c) 2011 John Mair (banisterfiend)
Pry.config.prompt = Pry::SIMPLE_PROMPT Pry.config.prompt = Pry::SIMPLE_PROMPT
end end
on :r, :require, "`require` a Ruby script at startup", true do |file| on :r, :require, "`require` a Ruby script at startup", :argument => true do |file|
Pry.config.requires << file Pry.config.requires << file
end end
on :I, "Add a path to the $LOAD_PATH", true do |path| on :I, "Add a path to the $LOAD_PATH", :argument => true do |path|
$LOAD_PATH << path $LOAD_PATH << path
end end
@ -130,7 +130,7 @@ Copyright (c) 2011 John Mair (banisterfiend)
on(:c, :context, on(:c, :context,
"Start the session in the specified context. Equivalent to `context.pry` in a session.", "Start the session in the specified context. Equivalent to `context.pry` in a session.",
true, :argument => true,
:default => "TOPLEVEL_BINDING" :default => "TOPLEVEL_BINDING"
) )
end.process_options do |opts| end.process_options do |opts|