summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndré Luis Leal Cardoso Junior <andrehjr@gmail.com>2022-04-09 19:30:39 -0300
committerGitHub <noreply@github.com>2022-04-09 19:30:39 -0300
commit6c531b9093a18a81155cadaf31f77944c495b44b (patch)
treedba0e0e863f2014d7b567192645db4698009ab78
parent38033e8db18a40e1a2db23c411dd6593b61ef14b (diff)
parent04da44f731d20d166643f51003e8ae06c19ba184 (diff)
downloadpry-6c531b9093a18a81155cadaf31f77944c495b44b.tar.gz
Merge pull request #2236 from andrehjr/enable-editor-code-flags
Configure `code` as a supported editor on Pry::Editor
-rw-r--r--lib/pry/editor.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/pry/editor.rb b/lib/pry/editor.rb
index c9d92b1a..d6d72a0d 100644
--- a/lib/pry/editor.rb
+++ b/lib/pry/editor.rb
@@ -105,7 +105,7 @@ class Pry
'--nofork' if blocking
when /^jedit/
'-wait' if blocking
- when /^mate/, /^subl/, /^redcar/
+ when /^mate/, /^subl/, /^redcar/, /^code/
'-w' if blocking
end
end
@@ -121,6 +121,8 @@ class Pry
"+#{line_number} #{file_name}"
when /^mate/, /^geany/
"-l #{line_number} #{file_name}"
+ when /^code/
+ "-g #{file_name}:#{line_number}"
when /^subl/
"#{file_name}:#{line_number}"
when /^uedit32/