如何自定义 tmux 列表会话配色方案?

如何自定义 tmux 列表会话配色方案?

请问,自定义 tmux 列表会话配色方案有哪些选项?

❯ tmux -V
tmux next-3.5

在此输入图像描述

tmux.conf

## COLORSCHEME: spoke (medium)
set-option -g status "on"

# default statusbar color
set-option -g status-style bg=colour234,fg=colour200 # bg=bg1, fg=fg1

set-window-option -g window-status-current-style bg=colour1,fg=colour1

# default window title colors
set-window-option -g window-status-style bg=colour204,fg=colour237 # bg=yellow, fg=bg1

# default window with an activity alert
set-window-option -g window-status-activity-style bg=colour237,fg=colour248 # bg=bg1, fg=fg3

# active window title colors
set-window-option -g window-status-current-style bg=colour1,fg=colour237 # fg=bg1

# pane border
set-option -g pane-active-border-style fg=colour250 #fg2
set-option -g pane-border-style fg=colour207 #bg1

# message infos
set-option -g message-style bg=colour235,fg=colour166 # bg=bg2, fg=fg1

# writing commands inactive
set-option -g message-command-style bg=colour239,fg=colour223 # bg=fg3, fg=bg1

# pane number display
set-option -g display-panes-active-colour colour250 #fg2
set-option -g display-panes-colour colour237 #bg1

# clock
set-window-option -g clock-mode-colour colour109 #blue

# bell
set-window-option -g window-status-bell-style bg=colour167,fg=colour235 # bg=red, fg=bg

## Theme settings mixed with colors (unfortunately, but there is no cleaner way)
set -g status-left ""
set-option -g status-justify "left"
set-option -g status-left-style none
set-option -g status-left-length "80"
set-option -g status-right-style none
set-option -g status-right-length "80"

set-window-option -g window-status-separator ""

set-option -g status-left "#[bg=colour235,fg=colour245] #S #[bg=colour234,fg=colour235,nobold,noitalics,nounderscore]"
set-option -g status-right "#[bg=colour234,fg=colour235 nobold, nounderscore, noitalics]#[bg=colour235,fg=colour239] %Y-%m-%d  %H:%M #[bg=colour235,fg=colour239,nobold,noitalics,nounderscore]#[bg=colour239,fg=colour234] #h "

set-window-option -g window-status-current-format "#[bg=colour235,fg=colour234,nobold,noitalics,nounderscore]#[bg=colour235,fg=colour166] #I #[bg=colour235,fg=colour166,bold] #W#{?window_zoomed_flag,*Z,} #[bg=colour234,fg=colour235,nobold,noitalics,nounderscore]"
set-window-option -g window-status-format "#[bg=colour235,fg=colour234,noitalics]#[bg=colour235,fg=colour239] #I #[bg=colour235,fg=colour239] #W #[bg=colour234,fg=colour235,noitalics]"

# color compatibility between tmux and vim
set -g default-terminal "xterm-256color" # or set -g default-terminal "screen-256color" 
set-option -ga terminal-overrides ",xterm-256color:Tc"

# vim: set ft=tmux tw=0 nowrap:

# enalbe vi mode
setw -g mode-keys vi

# start index at 1
set -g base-index 1
set -g pane-base-index 1

# enable mouse scroll and clickable windows
set-window-option -g mouse on

# reload config
bind-key r source-file ~/.tmux.conf \; display-message "Config reloaded..."

# resize panes
bind-key -r H resize-pane -L 5
bind-key -r J resize-pane -D 5
bind-key -r K resize-pane -U 5
bind-key -r L resize-pane -R 5

# cycle through panes
bind-key -r h select-pane -L
bind-key -r j select-pane -D
bind-key -r k select-pane -U
bind-key -r l select-pane -R

## toggle status bar
bind-key t set-option status

# send prefix to remote host
bind-key -n C-M-b send-prefix

相关内容