-
Notifications
You must be signed in to change notification settings - Fork 2
/
tmux.conf
107 lines (81 loc) · 2.64 KB
/
tmux.conf
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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
########
# Colors
########
#### COLOUR (Solarized dark)
# default statusbar colors
set-option -g status-style bg=default,fg=yellow,default
set-window-option -g window-status-current-style bg=default,fg=brightblue,bright
set-window-option -g window-status-style fg=brightblue,dim
# pane border
set-option -g pane-active-border-style fg=brightgreen,bg=default
# message text
set-option -g message-style bg=default,fg=brightred
# pane number display
set-option -g display-panes-active-colour blue
set-option -g display-panes-colour brightred
# clock
set-window-option -g clock-mode-colour green
# bell
set-window-option -g window-status-bell-style fg=black,bg=red #base02, red
######
# UI
######
# note: multiline string - whitespace number matters
set -g status-right '\
#[fg=green,dim,bg=default]#([ "$SSH_CLIENT" != "" ] && echo "<ssh>" )\
#[fg=colour33,dim,bg=default]#H\
#[fg=red,bg=default]#(uptime | cut -f 4-5 -d " " | cut -f 1 -d ",")\
#[fg=brightblue,bg=default]#[default]'
set -g status-left '\
#[fg=brightgreen,bg=default]#([ "$SSH_CLIENT" != "" ] && echo "☁ " )\
#[fg=yellow,bg=default][#S] '
set -g status-left-length 50
set -g status-right-length 100
set -g base-index 1
set -g renumber-windows on
# set -g window-status-format '#I:#{pane_current_command}'
# set -g window-status-current-format '#I:#{pane_current_command}#F'
set -g automatic-rename off
set -g default-terminal "xterm-256color"
set-option -ga terminal-overrides ",xterm-256color:Tc"
#######
# Modes
#######
set -g mouse on
set -s escape-time 10
set -g repeat-time 0
set -g set-titles off
# set-window-option -g mode-keys vi
#
# old version tmux use `bind -t`, be careful to enable this
#
# bind -T copy-mode-vi 'v' send -X begin-selection
# bind -T copy-mode-vi 'y' send -X copy-selection-and-cancel
set-option -g history-limit 3000
#############
# Key Binding
#############
bind r source-file ~/.tmux.conf \; display-message "Config reloaded...";
set -g prefix 'C-l'
unbind C-b
bind 'C-l' send-prefix
bind -n M-o select-pane -t :.+
bind M-t new-window -c "#{pane_current_path}"
bind -n M-1 select-window -t 1
bind -n M-2 select-window -t 2
bind -n M-3 select-window -t 3
bind -n M-4 select-window -t 4
bind -n M-5 select-window -t 5
bind -n M-6 select-window -t 6
bind -n M-7 select-window -t 7
bind -n M-8 select-window -t 8
bind -n M-9 select-window -t 9
# conflict with my emacs keyboard settings
# bind -n F3 previous-window
# bind -n F4 next-window
bind -n M-t new-window -c "#{pane_current_path}"
bind -n 'M-}' resize-pane -L
bind -n 'M-{' resize-pane -R
bind -n M-) switch-client -n
bind -n M-( switch-client -p
# do not bind 'M-[' key, this will cause bracket paste mode problem