Since I have my Caps-lock key mapped to Esc (due to Vim), I'd also like it in tmux.
Specifically, I'm trying to set Esc + a as the prefix:
set -g prefix Escape-a
However, this isn't working, and I get the error bad key: Escape-a
. Is this because Esc is not a modifier key? I'd really like this to work, as Esc is on the home row and very convenient to use.
This sequence:
set-option -g prefix Escape
unbind-key C-b
bind-key Escape send-prefix
...works for me. I'm using tmux-2.0
If you're on OS X you can achieve this with karabiner.
In your system preferences, change Caps-lock to Control instead of Esc. Then use karabiner to send Esc when you type Control by itself.
This gives your left pinky easy access to both Esc and Control. You can exit Vim's insert mode the way you already are, and you can set Control+a as your tmux prefix:
set -g prefix C-a
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With