From d77bfe285c70b16afb7de72fa61513c58bd88fd9 Mon Sep 17 00:00:00 2001 From: John Mair Date: Sun, 6 Jan 2013 21:43:41 +0100 Subject: [PATCH] set_file_and_dir(): now takes optional _pry_ and target args --- lib/pry/helpers/base_helpers.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/pry/helpers/base_helpers.rb b/lib/pry/helpers/base_helpers.rb index 85c17813..a1decdc7 100644 --- a/lib/pry/helpers/base_helpers.rb +++ b/lib/pry/helpers/base_helpers.rb @@ -47,7 +47,7 @@ class Pry end end - def set_file_and_dir_locals(file_name) + def set_file_and_dir_locals(file_name, _pry_=_pry_(), target=target()) return if !target or !file_name _pry_.last_file = File.expand_path(file_name) _pry_.inject_local("_file_", _pry_.last_file, target)