GitXplorerGitXplorer
M

tmux-mode-indicator

public
160 stars
8 forks
3 issues

Commits

List of commits on branch master.
Unverified
7027903adca37c54cb8f5fa99fc113b11c23c2c4

fix session option reading for custom indicator

MMunifTanjim committed 2 years ago
Unverified
11520829210a34dc9c7e5be9dead152eaf3a4423

fix indicator_style string manipulation

MMunifTanjim committed 3 years ago
Unverified
1ab550dd501ab8c0b4ad781a82cb4a9364a653e9

use local options for custom indicator

MMunifTanjim committed 4 years ago
Unverified
253df37841a7d4db54ddbabc2636667d5f98b0ae

support custom indicator

MMunifTanjim committed 4 years ago
Unverified
466cf0b07c769b623c3ea17993b600695341b3c3

add screenshots

MMunifTanjim committed 5 years ago
Unverified
06f419c9be69126f941283d49d0dac0f713759bd

add readme file

MMunifTanjim committed 5 years ago

README

The README file for this repository.

Tmux Mode Indicator

Plugin that displays prompt indicating currently active Tmux mode.

Prefix Prompt:
Prefix Prompt

Copy Prompt:
Copy Prompt

Sync Prompt:
Sync Prompt

Empty Prompt:
Empty Prompt

Note: This is a trimmed down version of the original tmux-prefix-highlight plugin.

Usage

Add #{tmux_mode_indicator} to the status-left or status-right option of Tmux. For example:

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

Installation

Installation with Tmux Plugin Manager

Add this repository as a TPM plugin in your .tmux.conf file:

set -g @plugin 'MunifTanjim/tmux-mode-indicator'

Press prefix + I in Tmux environment to install it.

Manual Installation

Clone this repository:

git clone https://github.com/MunifTanjim/tmux-mode-indicator.git ~/.tmux/plugins/tmux-mode-indicator

Add this line in your .tmux.conf file:

run-shell ~/.tmux/plugins/tmux-mode-indicator/mode_indicator.tmux

Reload Tmux configuration file with:

tmux source-file ~/.tmux.conf

Configuration Options

The following configuration options are available:

# prompt to display when tmux prefix key is pressed
set -g @mode_indicator_prefix_prompt ' WAIT '

# prompt to display when tmux is in copy mode
set -g @mode_indicator_copy_prompt ' COPY '

# prompt to display when tmux has synchronized panes
set -g @mode_indicator_sync_prompt ' SYNC '

# prompt to display when tmux is in normal mode
set -g @mode_indicator_empty_prompt ' TMUX '

# style values for prefix prompt
set -g @mode_indicator_prefix_mode_style 'bg=blue,fg=black'

# style values for copy prompt
set -g @mode_indicator_copy_mode_style 'bg=yellow,fg=black'

# style values for sync prompt
set -g @mode_indicator_sync_mode_style 'bg=red,fg=black'

# style values for empty prompt
set -g @mode_indicator_empty_mode_style 'bg=cyan,fg=black'

Custom Indicator

You can override the indicator at any time by setting these options:

# prompt to display instead of default mode indicators
set @mode_indicator_custom_prompt ' ---- '

# style values for custom prompt
set @mode_indicator_custom_mode_style 'default'

To revert back to the default mode indicators, unset those options:

set -u @mode_indicator_custom_prompt

set -u @mode_indicator_custom_mode_style

License

Licensed under the MIT License. Check the LICENSE file for details.