-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathtmux.config
77 lines (64 loc) · 2.55 KB
/
tmux.config
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
# apply settings
# tmux source-file ~/.tmux.conf
# Customization for key bindings.
# Check it using "C-a + ?".
## Make tmux like screen, using Ctrl+A
#unbind C-b
#set -g prefix ^A
#bind a send-prefix
## Use h and v for splitting.
unbind %
unbind '"'
bind | split-window -h
bind - split-window -v
# General configuration.
# $ tmux show-options -g
set -g mouse off
#set -g mode-mouse off
#set -g mouse-resize-pane off
#set -g mouse-select-pane off
#set -g mouse-select-window off
set-option -g default-shell /bin/zsh
set-option -g allow-rename off
set -g base-index 1
set -g display-time 5000
set -g repeat-time 1000
set -g status-keys vi
set -g status-utf8 on
set -g status-bg black
set -g status-fg white
set -g status-justify left
set -g status-interval 1
set -g status-left-length 20
set -g status-right-length 55
set -g status-left '#[fg=green][#[fg=white,bright]Session #[bg=black,fg=cyan]#S#[bg=black,fg=blue,dim]:#H#[fg=green]]'
#set -g status-left "#[fg=white,bright,bg=blue] Session #[fg=yellow,bright,bg=blue]#S #[default] |" # session-name
#set -g status-right "#[fg=blue,bright][#[fg=blue]#(pwd)#[fg=blue,bright]]#[fg=red][#[fg=green]#(cut -d ' ' -f 1-3 /proc/loadavg)#[fg=red]] #[fg=yellow,bright] %Y-%m-%d #[fg=green]%H:%M:%S #[fg=magenta,bright]"
set -g status-right "#[fg=red][#[fg=green]#(cut -d ' ' -f 1-3 /proc/loadavg)#[fg=red]]#[fg=yellow][#[fg=yellow]%H:%M #[fg=yellow]%a %m-%d#[fg=yellow]]"
# Inactive windows in status bar
set-window-option -g window-status-format '#[fg=cyan,dim]#I#[fg=blue]:#[default]#W#[fg=grey,dim]#F'
# Current or active window in status bar
#set-window-option -g window-status-current-bg yellow
#set-window-option -g window-status-current-fg black
set-window-option -g window-status-current-format '#[bg=blue,fg=cyan,bold]#I#[bg=blue,fg=cyan]:#[fg=white]#W#[fg=dim]#F'
# Alerted window in status bar. Windows which have an alert (bell, activity or content).
#set-window-option -g window-status-alert-fg red
#set-window-option -g window-status-alert-bg white
#Configuration for each window.
#$ tmux show-window-options -g
setw -g utf8 on
setw -g window-status-format " #I$ #W "
setw -g window-status-current-format " #I$ #W "
setw -g window-status-current-bg yellow
setw -g window-status-current-fg blue
setw -g window-status-current-attr default
#选择分割的窗格
bind k selectp -U # 选择上窗格
bind j selectp -D # 选择下窗格
bind h selectp -L # 选择左窗格
bind l selectp -R # 选择右窗格
# resize panel
bind -n S-Up resize-pane -U 1
bind -n S-Down resize-pane -D 1
bind -n S-Left resize-pane -L 1
bind -n S-Right resize-pane -R 1