extend/kernel: allow exec_editor to open multiple files at once
This commit is contained in:
parent
65d3c6e950
commit
358291e841
@ -389,10 +389,10 @@ module Kernel
|
|||||||
editor
|
editor
|
||||||
end
|
end
|
||||||
|
|
||||||
sig { params(filename: T.any(String, Pathname)).void }
|
sig { params(filenames: T.any(String, Pathname)).void }
|
||||||
def exec_editor(filename)
|
def exec_editor(*filenames)
|
||||||
puts "Editing #{filename}"
|
puts "Editing #{filenames.join "\n"}"
|
||||||
with_homebrew_path { safe_system(*which_editor.shellsplit, filename) }
|
with_homebrew_path { safe_system(*which_editor.shellsplit, *filenames) }
|
||||||
end
|
end
|
||||||
|
|
||||||
sig { params(args: T.any(String, Pathname)).void }
|
sig { params(args: T.any(String, Pathname)).void }
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user