You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This tmux tpm plugin allows you to lock your keybinds away for a while, until you need to use them again
Usage
Either use the configured bindings or run tmux toggle-mappings in you terminal to lock away all (other) bindings until you run it again.
You can use tmux lock-mappings and tmux unlock-mappings if you want to separate those behaviours.
Install the plugin with <prefix>I, unless you changed @tpm-install, in which case you should use the keybind you set.
Configuration
This plugins offers three options to be set in your tmux.conf with these defaults:
set -g @keylocker-toggle-bind 'C-g'set -g @keylocker-lock-bind 'None'set -g @keylocker-unlock-bind 'None'
to remove the pre-set binding set the related option option to None.
Note that these are a simple wrapper binds over the command aliases provided by the plugin.
You may also want to set your status bar to show whether or not your mappings are currently locked using the tmux option set by this plugin.
@keylocker-status will contain either the path to the file where the currently locked mappings are stored or 0.
Here are some examples with and without using a script:
set -g status-right "#{?@keylocker-status,#[fg=color255]#[bg=color208] LOCKED ,#[fg=color0]#[bg=color101] UNLOCKED }"
set -g status-right "#(~/.config/tmux/scripts/status/keylocker.bash)"