-
Notifications
You must be signed in to change notification settings - Fork 1
/
.tmux.conf
92 lines (71 loc) · 2.5 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
set -g @plugin 'tmux-plugins/tpm'
#list of plugins
set -g @plugin 'tmux-plugins/tmux-sensible'
set -g @plugin 'tmux-plugins/tmux-resurrect'
set -g @plugin 'tmux-plugins/tmux-yank'
# set -g @plugin 'janoamaral/tokyo-night-tmux'
set -g @plugin "arcticicestudio/nord-tmux"
# set -g @nord_tmux_no_patched_font "1"
#set -g @yank_with_mouse off
# allow to connect to display
set-option -g update-environment "SSH_ASKPASS SSH_AUTH_SOCK SSH_AGENT_PID SSH_CONNECTION WINDOWID XAUTHORITY"
# resurrect config
set -g @resurrect-processes 'schroot watch ccache distccmon-text'
# alacritty color support
set -g default-terminal screen-256color
set -g terminal-overrides ",alacritty:RGB"
# Enable locking
set -g lock-command vlock
bind l lock-client
bind L lock-session
# Style config, TODO replace with proper theme?
set -g status-style fg=black,bg=cyan
set -g window-status-current-style bg=yellow
set -g window-status-separator '|'
set -g window-active-style bg=default
set -g window-style bg=default
set -g pane-border-style bg=default
set -g pane-active-border-style fg=cyan
# Shortcut settings
unbind C-b
set -g prefix C-a
set -g base-index 1
set -g renumber-windows on
set -g pane-base-index 1
set -g mouse on
# reload config
bind r source-file ~/.tmux.conf \; display "Reloaded!"
# Splitting panes
unbind u
bind u split-window -v
bind o split-window -h
# killing pane
bind-key x kill-pane
# Navigation
bind -n C-h select-pane -L # beat test
bind -n C-j select-pane -D
bind -n C-k select-pane -U
bind -n C-l select-pane -R
bind -T copy-mode-vi C-h select-pane -L
bind -T copy-mode-vi C-j select-pane -D
bind -T copy-mode-vi C-k select-pane -U
bind -T copy-mode-vi C-l select-pane -R
# Maximize pane, would be nice to omit the prefix but C-m is handled as Enter and does not work easily
# unbind z
unbind Z
bind m resize-pane -Z
# copy
set-window-option -g mode-keys vi
#set-option -s set-clipboard off
unbind -T copy-mode-vi Enter
#unbind -T copy-mode-vi MouseDragEnd1Pane
bind -T copy-mode-vi v send-keys -X begin-selection
bind -T copy-mode-vi Enter send-keys -X copy-pipe-and-cancel 'xclip -se c -i'
bind -T copy-mode-vi MouseDown1Pane select-pane\; send-keys -X clear-selection
#bind -n MouseDrag1Pane if -Ft= '#{mouse_any_flag}' 'if -Ft= \"#{pane_in_mode}\" \"copy-mode -eM\" \"send-keys -M\"' 'copy-mode -eM'
bind P paste-buffer
# Do not copy selection and cancel copy mode
# Synchronize panes
bind a setw synchronize-panes
# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
run '~/.tmux/plugins/tpm/tpm'