-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathtmux.conf
More file actions
57 lines (56 loc) · 1.65 KB
/
tmux.conf
File metadata and controls
57 lines (56 loc) · 1.65 KB
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
# modify the prefix
# set -g prefix C-a
# unbind C-b
# modify the escape-time to 1ms, speed up the reponse
set -sg escape-time 1
# set the window-base
set -g base-index 1
# set the pane-base
setw -g pane-base-index 1
# reset ~/.tmux.conf
bind r source-file ~/.tmux.conf \; display "Reloaded ~/.tmux.conf"
# send-prefix to other program
bind C-a send-prefix
# split the pane
bind | split-window -h
bind - split-window -v
# set the move using vim-style
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
# switch the window
bind -r C-h select-window -t :-
bind -r C-l select-window -t :+
# set the size of pane
bind -r H resize-pane -L 5
bind -r J resize-pane -D 5
bind -r K resize-pane -U 5
bind -r L resize-pane -R 5
# set the color mode of tmux
set -g default-terminal "screen-256color"
# setting the status bar
set -g status-left-length 40
set -g status-left "#[fg=green]Session: #S #[fg=yellow]#I #[fg=cyan]#P"
set -g status-right "#[fg=cyan]%d %b %R"
# setting the fresh interval
set -g status-interval 60
# setting the utf-8 support
set -g status-utf8 on
# let window-list on center
set -g status-justify centre
# enable the notification of window-activity
setw -g monitor-activity on
set -g visual-activity on
# enable the vi mode
setw -g mode-keys vi
# short-cut key for copy mode
unbind [
bind Escape copy-mode
unbind p
bind p paste-buffer
bind -t vi-copy 'v' begin-selection
bind -t vi-copy 'y' copy-selection
# use xclip with tmux in linux
bind C-c run "tmux save-buffer - | xlip -i -sel clipboard"
bind C-v run "tmux set buffer \"$(xlip -o -sel clipboard)\"; tmux paste-buffer"