-
Notifications
You must be signed in to change notification settings - Fork 27
/
.tmux.conf
201 lines (168 loc) · 10.1 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
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
# Use ` rather than C-b (like in Vim)
unbind C-b
set -g prefix `
bind-key ` send-prefix
# login shell for new windows/pane
set-option -g default-shell /usr/bin/zsh
# Improve colors
set -g default-terminal 'xterm-256color'
# Set scrollback buffer to 50000
set -g history-limit 50000
# By default, status msg disappears in the blink of an eye (750ms)
set-option -g display-time 2000
# By default, pane number disappears in 1 s
set-option -g display-panes-time 2000
# Lock the session after 60 mins of inactivity. Sometimes, it is good to protect your screen to make sure other's can't see enough.
set-option -g lock-after-time 3600
# Window index will start with 1
set-option -g base-index 1
# Pane index will start with 1
set-window-option -g pane-base-index 1
set-option -g renumber-windows on
# Automatically set client terminal window title
set-option -g set-titles on
# Automatically set window title
set-window-option -g automatic-rename on
set-option -g allow-rename on
# Tmux adds a short, almost imperceptible delay between the commands that can cause funny behavior when running vim inside tmux.
set-option -s escape-time 0
# Split panes using | and -
unbind -
unbind %
bind - split-window -v
unbind '"'
bind '\' split-window -h
# Reload config file
bind r source-file ~/.tmux.conf \; display ".tmux.conf reloaded!"
# Switch panes using Alt-arrow without prefix
bind -n M-Left select-pane -L
bind -n M-Right select-pane -R
bind -n M-Up select-pane -U
bind -n M-Down select-pane -D
# Enable mouse mode
set -g mouse on
######################
### DESIGN CHANGES ###
######################
# loud or quiet?
set -g visual-activity off
set -g visual-bell off
set -g visual-silence off
setw -g monitor-activity off
set -g bell-action none
# Powerline Double Magenta - Tmux Themepack
# https://github.com/jimeh/tmux-themepack
# Themepack format options
set -g @themepack-status-left-area-left-format " #(whoami)"
set -g @themepack-status-left-area-middle-format " #S"
set -g @themepack-status-left-area-right-format "#I:#P"
set -g @themepack-status-right-area-left-format " %H:%M:%S"
set -g @themepack-status-right-area-middle-format " %d-%b-%y"
set -g @themepack-status-right-area-right-format " #H"
set -g @themepack-window-status-current-format "#{?client_prefix,•,}#I:#W#F"
set -g @themepack-window-status-format "#{?client_prefix,•,}#I:#W#F"
# Powerline color options
set -g @powerline-color-main-1 "#ea76cb" # colour127
set -g @powerline-color-main-2 "#cba6f7" # colour127
set -g @powerline-color-main-3 colour129
set -g @powerline-color-black-1 black
set -g @powerline-color-grey-1 colour233
set -g @powerline-color-grey-2 colour235
set -g @powerline-color-grey-3 colour238
set -g @powerline-color-grey-4 colour240
set -g @powerline-color-grey-5 colour243
set -g @powerline-color-grey-6 colour245
# Powerline Double Override
set -gF @powerline-status-right-area-right-bg "#{@powerline-color-main-1}"
# Powerline options
set -gF @powerline-color-activity-1 "#{@powerline-color-grey-6}"
set -gF @powerline-status-bg "#{@powerline-color-grey-1}"
set -gF @powerline-status-fg "#{@powerline-color-grey-4}"
set -gF @powerline-status-left-area-left-bg "#{@powerline-color-main-1}"
set -gF @powerline-status-left-area-left-fg "#{@powerline-status-bg}"
set -gF @powerline-status-left-area-middle-bg "#{@powerline-status-fg}"
set -gF @powerline-status-left-area-middle-fg "#{@powerline-status-bg}"
set -gF @powerline-status-left-area-right-bg "#{@powerline-color-grey-2}"
set -gF @powerline-status-left-area-right-fg "#{@powerline-status-fg}"
set -gF @powerline-status-left-bg "#{@powerline-color-grey-1}"
set -gF @powerline-status-left-fg "#{@powerline-color-grey-5}"
set -gF @powerline-status-right-area-left-bg "#{@powerline-color-grey-2}"
set -gF @powerline-status-right-area-left-fg "#{@powerline-status-fg}"
set -gF @powerline-status-right-area-middle-bg "#{@powerline-status-fg}"
set -gF @powerline-status-right-area-middle-fg "#{@powerline-status-bg}"
set -gF @powerline-status-right-area-right-bg "#{@powerline-color-main-1}"
set -gF @powerline-status-right-area-right-fg "#{@powerline-status-bg}"
set -gF @powerline-status-right-bg "#{@powerline-color-grey-1}"
set -gF @powerline-status-right-fg "#{@powerline-color-grey-5}"
# Theme options
set -gF @theme-clock-mode-colour "#{@powerline-color-main-1}"
set -g @theme-clock-mode-style 24
set -gF @theme-display-panes-active-colour "#{@powerline-color-grey-6}"
set -gF @theme-display-panes-colour "#{@powerline-color-grey-1}"
set -gF @theme-message-bg "#{@powerline-color-main-1}"
set -gF @theme-message-command-bg "#{@powerline-color-main-1}"
set -gF @theme-message-command-fg "#{@powerline-color-black-1}"
set -gF @theme-message-fg "#{@powerline-color-black-1}"
set -gF @theme-mode-bg "#{@powerline-color-main-1}"
set -gF @theme-mode-fg "#{@powerline-color-black-1}"
set -g @theme-pane-active-border-bg default
set -gF @theme-pane-active-border-fg "#{@powerline-color-main-1}"
set -g @theme-pane-border-bg default
set -gF @theme-pane-border-fg "#{@powerline-color-grey-3}"
set -gF @theme-status-bg "#{@powerline-status-bg}"
set -gF @theme-status-fg "#{@powerline-status-fg}"
set -g @theme-status-interval 1
set -g @theme-status-justify centre
set -gF @theme-status-left "#[fg=#{@powerline-status-left-area-left-fg},bg=#{@powerline-status-left-area-left-bg},bold] #{@themepack-status-left-area-left-format} #[fg=#{@powerline-status-left-area-left-bg},bg=#{@powerline-status-left-area-middle-bg},nobold]#[fg=#{@powerline-status-left-area-middle-fg},bg=#{@powerline-status-left-area-middle-bg}] #{@themepack-status-left-area-middle-format} #[fg=#{@powerline-status-left-area-middle-bg},bg=#{@powerline-status-left-area-right-bg}]#[fg=#{@powerline-status-left-area-right-fg},bg=#{@powerline-status-left-area-right-bg}] #{@themepack-status-left-area-right-format} #[fg=#{@powerline-status-left-area-right-bg},bg=#{@theme-status-bg},nobold]"
set -gF @theme-status-left-bg "#{@powerline-status-left-bg}"
set -gF @theme-status-left-fg "#{@powerline-status-left-fg}"
set -g @theme-status-left-length 40
set -gF @theme-status-right "#[fg=#{@powerline-status-right-area-left-bg},bg=#{@theme-status-bg}]#[fg=#{@powerline-status-right-area-left-fg},bg=#{@powerline-status-right-area-left-bg}] #{@themepack-status-right-area-left-format} #[fg=#{@powerline-status-right-area-middle-bg},bg=#{@powerline-status-right-area-left-bg}]#[fg=#{@powerline-status-right-area-middle-fg},bg=#{@powerline-status-right-area-middle-bg}] #{@themepack-status-right-area-middle-format} #[fg=#{@powerline-status-right-area-right-bg},bg=#{@powerline-status-right-area-middle-bg}]#[fg=#{@powerline-status-right-area-right-fg},bg=#{@powerline-status-right-area-right-bg},bold] #{@themepack-status-right-area-right-format} "
set -gF @theme-status-right-bg "#{@powerline-status-right-bg}"
set -gF @theme-status-right-fg "#{@powerline-status-right-fg}"
set -g @theme-status-right-length 150
set -gF @theme-window-status-activity-bg "#{@theme-status-bg}"
set -gF @theme-window-status-activity-fg "#{@powerline-color-activity-1}"
set -g @theme-window-status-separator ""
set -gF @theme-window-status-current-bg "#{@powerline-color-black-1}"
set -gF @theme-window-status-current-fg "#{@powerline-color-main-2}"
set -gF @theme-window-status-format " #{@themepack-window-status-format} "
set -gF @theme-window-status-current-format "#[fg=#{@theme-status-bg},bg=#{@theme-window-status-current-bg}]#[fg=#{@theme-window-status-current-fg},nobold] #{@themepack-window-status-current-format} #[fg=#{@theme-status-bg},bg=#{@theme-window-status-current-bg},nobold]"
# Customizable prefixes and suffixes for @theme-* format options
set -g @theme-status-left-prefix ""
set -g @theme-status-left-suffix ""
set -g @theme-status-right-prefix ""
set -g @theme-status-right-suffix ""
set -g @theme-window-status-current-prefix ""
set -g @theme-window-status-current-suffix ""
set -g @theme-window-status-prefix ""
set -g @theme-window-status-suffix ""
# Apply prefixes and suffixes to @theme-* format options
set -gqF @theme-status-left "#{@theme-status-left-prefix}#{@theme-status-left}#{@theme-status-left-suffix}"
set -gqF @theme-status-right "#{@theme-status-right-prefix}#{@theme-status-right}#{@theme-status-right-suffix}"
set -gqF @theme-window-status-current-format "#{@theme-window-status-current-prefix}#{@theme-window-status-current-format}#{@theme-window-status-current-suffix}"
set -gqF @theme-window-status-format "#{@theme-window-status-prefix}#{@theme-window-status-format}#{@theme-window-status-suffix}"
# Apply @theme-* options to Tmux
set -gF display-panes-active-colour "#{@theme-display-panes-active-colour}"
set -gF display-panes-colour "#{@theme-display-panes-colour}"
set -gF message-command-style "fg=#{@theme-message-command-fg},bg=#{@theme-message-command-bg}"
set -gF message-style "fg=#{@theme-message-fg},bg=#{@theme-message-bg}"
set -gF status-interval "#{@theme-status-interval}"
set -gF status-justify "#{@theme-status-justify}"
set -gF status-left "#{@theme-status-left}"
set -gF status-left-length "#{@theme-status-left-length}"
set -gF status-left-style "fg=#{@theme-status-left-fg},bg=#{@theme-status-left-bg}"
set -gF status-right "#{@theme-status-right}"
set -gF status-right-length "#{@theme-status-right-length}"
set -gF status-right-style "fg=#{@theme-status-right-fg},bg=#{@theme-status-right-bg}"
set -gF status-style "fg=#{@theme-status-fg},bg=#{@theme-status-bg}"
set -gwF clock-mode-colour "#{@theme-clock-mode-colour}"
set -gwF clock-mode-style "#{@theme-clock-mode-style}"
set -gwF mode-style "fg=#{@theme-mode-fg},bg=#{@theme-mode-bg}"
set -gwF pane-active-border-style "fg=#{@theme-pane-active-border-fg},bg=#{@theme-pane-active-border-bg}"
set -gwF pane-border-style "fg=#{@theme-pane-border-fg},bg=#{@theme-pane-border-bg}"
set -gwF window-status-activity-style "fg=#{@theme-window-status-activity-fg},bg=#{@theme-window-status-activity-bg}"
set -gwF window-status-format "#{@theme-window-status-format}"
set -gwF window-status-current-format "#{@theme-window-status-current-format}"
set -gwF window-status-current-style "fg=#{@theme-window-status-current-fg},bg=#{@theme-window-status-current-bg}"
set -gwF window-status-separator "#{@theme-window-status-separator}"