From 46bbaacf5f6eacbc7b36ade5d1c256390d1eb8af Mon Sep 17 00:00:00 2001 From: Determinant Date: Wed, 20 May 2020 16:52:22 -0400 Subject: add another switch --- README.rst | 8 +++----- tmux-colortag.tmux | 6 ++++++ 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/README.rst b/README.rst index 4889e40..10c6c42 100644 --- a/README.rst +++ b/README.rst @@ -28,11 +28,9 @@ Installation - Hit prefix + I to fetch the plugin and source it. -- Optional: for the best experience, try to use a short status update interval: - - :: - - set -g status-interval 2 +- Optional: for the best experience, this plugin assumes a short status update + interval. To change it back, specify ``TMUX_COLORTAG_SET_INTERVAL=no`` or + directly override the setting in your tmux config file. - Optional: if you don't like powerline symbols, feel free to change them by specifying the following environment variables to override the default: diff --git a/tmux-colortag.tmux b/tmux-colortag.tmux index c41a0b3..77ea8e4 100755 --- a/tmux-colortag.tmux +++ b/tmux-colortag.tmux @@ -5,6 +5,12 @@ TMUX_ARROW_SYMBOL_L1="${TMUX_ARROW_SYMBOL_L1:-$(printf '\ue0b6')}" TMUX_ARROW_SYMBOL_L2="${TMUX_ARROW_SYMBOL_L2:-$(printf '\ue0b7')}" TMUX_ARROW_SYMBOL_R1="${TMUX_ARROW_SYMBOL_R1:-$(printf '\ue0b4')}" TMUX_ARROW_SYMBOL_R2="${TMUX_ARROW_SYMBOL_R2:-$(printf '\ue0b5')}" +TMUX_COLORTAG_SET_INTERVAL="${TMUX_COLORTAG_SET_INTERVAL:-yes}" + +if [[ "$TMUX_COLORTAG_SET_INTERVAL" == yes ]]; then + set -g status on + set -g status-interval 2 +fi tmux set -g status-style bg=colour237 tmux set -g message-style fg=colour237,bg=colour248 -- cgit v1.2.3