From cf57d9a80d72c107eeb6a57ab69e6b7622855d39 Mon Sep 17 00:00:00 2001 From: John Mair Date: Sun, 10 Apr 2011 02:23:24 +1200 Subject: [PATCH] added 'reset' command (exec("pry")) to bin/pry executable --- bin/pry | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/bin/pry b/bin/pry index 634bd958..94fb2bd4 100644 --- a/bin/pry +++ b/bin/pry @@ -68,6 +68,13 @@ end.parse! # invoked via cli Pry.cli = true +class Pry::Commands + command "reset", "Reset the REPL to a clean state." do + output.puts "Pry reset." + exec("pry") + end +end + # load ~/.pryrc, if not suppressed with -f option Pry.should_load_rc = false if !options[:loadrc]