lib/textbringer/utils.rb in textbringer-0.1.9 vs lib/textbringer/utils.rb in textbringer-0.2.0

- old
+ new

@@ -158,10 +158,10 @@ def complete_for_minibuffer(s, candidates) candidates.select { |i| i.start_with?(s) } end - def read_buffer(prompt, default: (Buffer.last || Buffer.current)&.name) + def read_buffer(prompt, default: Buffer.other.name) f = ->(s) { complete_for_minibuffer(s, Buffer.names) } read_from_minibuffer(prompt, completion_proc: f, default: default) end def read_command_name(prompt)