Ver código fonte

make tmux powerline session info less cryptic, highlight current window

Weiyi Lou 13 anos atrás
pai
commit
bbd7019085

+ 6 - 0
tmux/tmux-powerline-custom/segments/tmux_session_info.sh

@@ -0,0 +1,6 @@
+#!/usr/bin/env sh
+# Prints tmux session info.
+# Assuems that [ -n "$TMUX"].
+tmux display-message -p 'Session: [#S]'
+
+exit 0

+ 1 - 1
tmux/tmux-powerline-custom/status-left.sh

@@ -23,7 +23,7 @@ mute_status_check "left"
 # Segments
 
 declare -A tmux_session_info
-tmux_session_info+=(["script"]="${segments_path}/tmux_session_info.sh")
+tmux_session_info+=(["script"]="${custom_segments_path}/tmux_session_info.sh")
 tmux_session_info+=(["foreground"]="colour234")
 tmux_session_info+=(["background"]="colour148")
 tmux_session_info+=(["separator"]="${separator_right_bold}")

+ 4 - 0
tmux/tmux.conf

@@ -104,3 +104,7 @@ set-option -g status-left-length 60
 set-option -g status-right-length 90
 set-option -g status-left "#(~/dotfiles/tmux/tmux-powerline-custom/status-left.sh)"
 set-option -g status-right "#(~/dotfiles/tmux/tmux-powerline-custom/status-right.sh)"
+
+# Highlight current window
+set -g window-status-current-bg red
+set -g window-status-current-fg white