pentest-distro-builder/filesystem/root/.tmux/plugins/tmux-prefix-highlight
Kaj Forney 582f5b5f5c Add autologin and custom tmux config.
Former-commit-id: 09eacc3f3f761c2b3454d20356ba085d18bdb722
Former-commit-id: 89d8a1302bd2a72239fbe9ad9820be4ecda76cab
2018-09-27 17:40:01 -06:00
..
screenshots Add autologin and custom tmux config. 2018-09-27 17:40:01 -06:00
LICENSE Add autologin and custom tmux config. 2018-09-27 17:40:01 -06:00
prefix_highlight.tmux Add autologin and custom tmux config. 2018-09-27 17:40:01 -06:00
README.md Add autologin and custom tmux config. 2018-09-27 17:40:01 -06:00

Tmux prefix highlight

Plugin that highlights when you press tmux prefix key. Inspired by this thread on stackoverflow.

Many thanks to @obxhdx for showing me this trick.

Prefix off: prefix_off

Prefix on: prefix_on

Usage

Just add #{prefix_highlight} to your left/right status bar.

set -g status-right '#{prefix_highlight} | %a %Y-%m-%d %H:%M'

The plugin can also be configured to show when copy mode is active; see the Configurations section for details.

Add plugin to the list of TPM plugins:

set -g @plugin 'tmux-plugins/tmux-prefix-highlight'

Press prefix + I to install it.

Manual Installation

Clone the repo:

$ git clone https://github.com/tmux-plugins/tmux-prefix-highlight.git ~/clone/path

Add this line to your .tmux.conf:

run-shell ~/clone/path/prefix_highlight.tmux

Reload TMUX environment with:

$ tmux source-file ~/.tmux.conf

Configurations

The colors used for the prefix highlight can be configured:

set -g @prefix_highlight_fg 'white' # default is 'colour231'
set -g @prefix_highlight_bg 'blue'  # default is 'colour04'

The plugin can also be configured to show when copy mode is active. If enabled, the #{prefix_highlight} token will be replaced with the string Copy when copy mode is enabled. The style for copy mode can be configured as a comma-separated list of colors and attributes:

set -g @prefix_highlight_show_copy_mode 'on'
set -g @prefix_highlight_copy_mode_attr 'fg=black,bg=yellow,bold' # default is 'fg=default,bg=yellow'

Additionally, the plugin can be configured to attach optional affixes to the value contained in #{prefix_highlight}. (e.g. < ^B >)

set -g @prefix_highlight_output_prefix '< '
set -g @prefix_highlight_output_suffix ' >'

License

MIT