-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.tmux.conf
107 lines (78 loc) · 2.98 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
# =============
# === Basic ===
# =============
set -sg escape-time 0
set-window-option -g mode-keys vi
set -g renumber-windows on
# set -g pane-border-format "#{pane_index} #T"
set -g display-panes-time 4000
set -g default-terminal "screen-256color"
set -ag terminal-overrides ",xterm-256color:RGB"
# set -g window-status-current-style "fg=green,bg=black,bold"
# set -g window-status-separator "|"
# set -g status-left "| #S |"
set -g mouse on
set -gq allow-passthrough on
# ==============
# === Keymap ===
# ==============
# Keys can be set.
# a [b] [e] [g] [h] [j] [k] [l] [u] [v] y
unbind C-b
set -g prefix C-a
bind C-a send-prefix
bind C-r source-file ~/.tmux.conf \; display "Refreshed tmux configure."
bind C-g set -g status
# bind S choose-tree # NOTE: Never used. So disable this.
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
bind H swap-pane -L
bind J swap-pane -D
bind K swap-pane -U
bind L swap-pane -R
bind -r C-h resize-pane -L 5
bind -r C-j resize-pane -D 5
bind -r C-k resize-pane -U 5
bind -r C-l resize-pane -R 5
bind c new-window -c "#{pane_current_path}"
bind g new-window -c "#{pane_current_path}" -a
bind v split-window -h -c "#{pane_current_path}"
bind b split-window -v -c "#{pane_current_path}"
bind u command-prompt "join-pane -t :'%%' -h"
# bind C-m command-prompt "move-window -t :'%%'"
# bind C-s command-prompt "run-shell '~/.scripts/tmux/rename_window.sh %%'"
bind C-s command-prompt "swap-window -d -t :'%%'"
bind C-e command-prompt -p "New pane title:" 'select-pane -T "%%"'
bind e command-prompt "select-pane -t '%%'"
bind C-w last-window
bind C-p last-pane
bind x confirm-before -p "Kill pane '#P'? (y/n)" kill-pane
bind C-x confirm-before -p "Kill window '#W'? (y/n)" kill-window
bind -T copy-mode-vi 'v' send -X rectangle-off \; send -X begin-selection
bind -T copy-mode-vi 'C-v' send -X rectangle-on \; send -X begin-selection
bind -T copy-mode-vi 'y' send -X copy-selection-and-cancel
# ==================================
# === TokyoNight colors for Tmux ===
# ==================================
set -g mode-style "fg=#7aa2f7,bg=#3b4261"
set -g message-style "fg=#7aa2f7,bg=#3b4261"
set -g message-command-style "fg=#7aa2f7,bg=#3b4261"
set -g pane-border-style "fg=#3b4261"
set -g pane-active-border-style "fg=#7aa2f7"
set -g status "on"
set -g status-justify "left"
set -g status-style "fg=#7aa2f7,bg=#1f2335"
set -g status-left-length "100"
set -g status-right-length "100"
set -g status-left-style NONE
set -g status-right-style NONE
set -g status-left "#[fg=#1d202f,bg=#7aa2f7,bold] #S "
# set -g status-right " #[fg=#7aa2f7,bg=#3b4261] %Y-%m-%d %H:%M #[fg=#1d202f,bg=#7aa2f7,bold] #h "
set -g status-right "#[fg=#1d202f,bg=#7aa2f7,bold] #h "
setw -g window-status-activity-style "underscore,fg=#a9b1d6,bg=#1f2335"
setw -g window-status-separator ""
setw -g window-status-style "NONE,fg=#a9b1d6,bg=#1f2335"
setw -g window-status-format " #I: #W #F "
setw -g window-status-current-format "#[fg=#7aa2f7,bg=#3b4261,bold] #I: #W #F "