-
Notifications
You must be signed in to change notification settings - Fork 0
/
dot_tmux.conf
63 lines (54 loc) · 1.97 KB
/
dot_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
# ~/.tmux.conf
# zoug
#
# tmux configuration
#
# example of setting F20 as prefix. Not used anymore.
# I now use "keyd" to remap directly the key(s) to use to Control-B. keyd works with any compositor/Xorg/Wayland...
## see $(man keyd) and /etc/keyd/default.conf
## this is better because I don't need this config for the prefix to work, useful for SSH hosts. The keyd config is:
##
##[ids]
##*
##[main]
### Remap ² to Control-B
### Find the name of the key you want to remap with $(keyd monitor)
##grave = C-b
##
#set-option -g prefix S-F8
#bind-key S-F8 send-prefix
# you could also unbind Control-B but I like to keep it as backup
#unbind-key C-b
# I use tmux TPM for plugins
# do $(git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm)
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-sensible'
set -g @plugin "janoamaral/tokyo-night-tmux"
set -g @plugin 'christoomey/vim-tmux-navigator'
set -g @plugin 'tmux-plugins/tmux-yank'
set -g @plugin 'tmux-plugins/tmux-resurrect'
# disable repeating commands without repressing prefix
#set -g repeat-time 1
# vim mode
setw -g mode-keys vi
# same keybindings as vim for copy mode (prefix+[)
bind-key -T copy-mode-vi v send-keys -X begin-selection
bind-key -T copy-mode-vi C-v send-keys -X rectangle-toggle
bind-key -T copy-mode-vi y send-keys -X copy-selection-and-cancel
# navigation between panes, vim style
bind -r h select-pane -L
bind -r j select-pane -D
bind -r k select-pane -U
bind -r l select-pane -R
# resize panes
bind -r H resize-pane -L 2
bind -r J resize-pane -D 2
bind -r K resize-pane -U 2
bind -r L resize-pane -R 2
bind -r & kill-window
# fix color support in tmux
# see here for a handy command to display colors: https://blog.jpalardy.com/posts/fixing-tmux-for-256-colors/
# followed this: https://gist.github.com/andersevenrud/015e61af2fd264371032763d4ed965b6
set -sg terminal-overrides ",*:RGB"
# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
run '~/.tmux/plugins/tpm/tpm'