-
Notifications
You must be signed in to change notification settings - Fork 0
/
.tmux.conf
140 lines (110 loc) · 3.68 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
# List of plugins
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-sensible'
set -g @plugin 'sainnhe/tmux-fzf'
TMUX_FZF_ORDER="pane|window|clipboard|command|process"
TMUX_FZF_LAUNCH_KEY="C-f"
TMUX_FZF_MENU=\
"quick-swap-pane\ntmux swap-pane && tmux select-pane -m && tmux select-pane -m\n"\
# set -g @plugin 'erikw/tmux-powerline'
# set -g @plugin 'tmux-plugins/tmux-resurrect'
# set -g @resurrect-dir '$HOME/.tmux/.resurrect'
# set -g @resurrect-save 'C-l'
# set -g @resurrect-restore 'C-k'
# set -g @plugin 'spywhere/tmux-named-snapshot'
# easy motion
set -g @plugin 'schasse/tmux-jump'
# system clipboard
set -g @plugin 'tmux-plugins/tmux-yank'
# # translator
# set -g @plugin 'sainnhe/tmux-translator'
# # the key to trigger translation
# set -g @tmux-translator "t"
# # the width of popup window
# set -g @tmux-translator-width "50%"
# # the height of popup window
# set -g @tmux-translator-height "50%"
# # translate from
# set -g @tmux-translator-from "en"
# # translate to
# set -g @tmux-translator-to "kr"
# # engine
# set -g @tmux-translator-engine "google"
# Other examples:
# set -g @plugin 'github_username/plugin_name'
# set -g @plugin 'github_username/plugin_name#branch'
# set -g @plugin '[email protected]:user/plugin'
# set -g @plugin '[email protected]:user/plugin'
# Initialize TMUX plugin manager (keep this line at the very bottom of
# tmux.conf)
if "test ! -d ~/.tmux/plugins/tpm" \
"run 'git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm && ~/.tmux/plugins/tpm/bin/install_plugins'"
run '~/.tmux/plugins/tpm/tpm'
# keyboard escape time
set -g escape-time 10
# mouse scroll
# set -g mouse on
set -g terminal-overrides 'xterm*:smcup@:rmcup@'
# 256 color
set -g default-terminal "screen-256color"
set -g status-keys vi
setw -g mode-keys vi
# Change prefix bind-key
unbind C-b
set -g prefix C-a
bind-key C-a send-prefix
bind | split-window -h
bind C-s set-option -g status
# Use Alt-arrow keys without prefix key to switch panes
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
# bind h select-pane -L
# bind l select-pane -R
# bind k select-pane -U
# bind j select-pane -D
# Shift arrow to switch windows
bind -n S-Left previous-window
bind -n S-Right next-window
bind -r H previous-window
bind -r L next-window
# Zoom
bind -n M-z resize-pane -Z
# Mark
bind -n M-m select-pane -m
# scrollback buffer size increase
set -g history-limit 100000
# change window order
# bind-key -n C-S-Left swap-pane -D
# bind-key -n C-S-Right swap-pane -D
bind-key -n C-S-Left swap-pane -s {left-of}
bind-key -n C-S-Right swap-pane -s {right-of}
bind-key -n C-S-Up swap-pane -s {up-of}
bind-key -n C-S-Down swap-pane -s {down-of}
bind-key -n C-S-Left swap-window -t -1\; select-window -t -1
bind-key -n C-S-Right swap-window -t +1\; select-window -t +1
# disable window name auto change
set-option -g allow-rename off
# bar color
set -g status-bg black
set -g status-fg white
# key binding for ALT+num
# switch windows alt+number
bind-key -n M-0 select-window -t 0
bind-key -n M-1 select-window -t 1
bind-key -n M-2 select-window -t 2
bind-key -n M-3 select-window -t 3
bind-key -n M-4 select-window -t 4
bind-key -n M-5 select-window -t 5
bind-key -n M-6 select-window -t 6
bind-key -n M-7 select-window -t 7
bind-key -n M-8 select-window -t 8
bind-key -n M-9 select-window -t 9
bind-key -n M-q display-panes
# pane number display
# set-option -g display-panes-active-colour colour1 #blue
# set-option -g display-panes-colour colour3 #orange
# set-option -g display-panes-active-colour colour33 #blue
# set-option -g display-panes-colour colour166 #orange
if-shell "test -f ~/.tmux/.tmux.theme.conf" "source ~/.tmux/.tmux.theme.conf"