I would like to bind the tmux
find-window
prompt to pressing and releasing Shift twice.
I have already tried
bind-key -n S-S command-prompt "find-window -N '%%'"
This results in no error message, checked with :show-messages
, but does not trigger the action when double-tapping Shift.
Best Answer
You can use xcape under x11 to configure Shift to emit e.g. Alt+Ctrl+Shift+F12 when tapped and released. Then you would declare that as a secondary
tmux
escape key, and assign a Key-binding to "Alt+Ctrl+Shift+F12" forcommand-prompt "find-window -N '%%'"
The exact sequence of commands:
At shell prompt:
At tmux prompt:
Now double-tap Shift_L, and on the bottom left of your
tmux
you will see(find-window)
.With
Shift_R=Alt_L|Control_R|Shift_L|F11
you can use Shift_L for innertmux
, and Shift_R for outertmux
, if you nest them.Note: I had previously posted this answer with F15, but that did not work as expected , because @Gilles says:
F13
-F20
need to be declared interminfo
.