mirror of
https://github.com/junegunn/fzf.git
synced 2026-10-28 08:05:53 +00:00
Pass bracketed paste actions through wait/track block
A pasted character firing a wait-arming binding swallowed the subsequent bracketed-paste-end, leaving t.pasting set forever and suppressing queryChanged for all later input. Let paste begin/end through the block so pasting state is maintained and the search for the edited query is dispatched.
This commit is contained in:
1 parent
743930a38d
commit
978ded5cd0
3 files changed
+26
-3
No files matched your search
@@ -177,6 +177,12 @@ class Tmux
|
||||
system('tmux', 'setb', str, ';', 'pasteb', '-t', win, ';', 'send-keys', '-t', win, 'Enter')
|
||||
end
|
||||
|
||||
# Paste with bracketed paste control codes so fzf sees
|
||||
# bracketed-paste-begin/end around the content
|
||||
def paste_bracketed(str)
|
||||
system('tmux', 'setb', str, ';', 'pasteb', '-p', '-t', win)
|
||||
end
|
||||
|
||||
def capture
|
||||
go(%W[capture-pane -p -J -t #{win}]).map(&:rstrip).reverse.drop_while(&:empty?).reverse
|
||||
end
|
||||
|
||||
Reference in new issue
Block a user