-
Notifications
You must be signed in to change notification settings - Fork 1
/
tmux.conf
52 lines (45 loc) · 2.14 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
# List of plugins ctrl + b + I to install
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-sensible'
set -g @plugin 'dracula/tmux'
# setting dracula tmux displaying
# https://draculatheme.com/tmux
set -g @dracula-plugins "cpu-usage ram-usage"
set -g @dracula-show-powerline false
set -g @dracula-show-left-sep
set -g @dracula-show-left-icon smiley
set -g @dracula-left-icon-padding 1
set -g @dracula-border-contrast true
set -g @dracula-show-fahrenheit false
# Use vim keybindings in copy mode
setw -g mode-keys vi
set-option -g set-titles on
# Add truecolor support
# set-option -ga terminal-overrides ",alacritty:Tc"
# set -as terminal-overrides ',xterm*:sitm=\E[3m'
# Default terminal is 256 colors
# set -g default-terminal "xterm-256color"
set-option -g default-terminal "screen-256color"
setw -g xterm-keys on
set -s escape-time 10 # faster command sequences
set -sg repeat-time 600 # increase repeat timeout
set -s focus-events on
setw -q -g utf8 on
set -g base-index 1 # start windows numbering at 1
setw -g pane-base-index 1 # make pane numbering consistent with windows
# Making undercurls work properly in Tmux
set -g default-terminal "${TERM}"
set -as terminal-overrides ',*:Smulx=\E[4::%p1%dm' # undercurl support
set -as terminal-overrides ',*:Setulc=\E[58::2::%p1%{65536}%/%d::%p1%{256}%/%{255}%&%d::%p1%{255}%&%d%;m' # underscore colours - needs tmux-3.0
is_vim='echo "#{pane_current_command}" | grep -iqE "(^|\/)g?(view|n?vim?)(diff)?$"'
bind -n C-h if-shell "$is_vim" "send-keys C-h" "select-pane -L"
bind -n C-j if-shell "$is_vim" "send-keys C-j" "select-pane -D"
bind -n C-k if-shell "$is_vim" "send-keys C-k" "select-pane -U"
bind -n C-l if-shell "$is_vim" "send-keys C-l" "select-pane -R"
# bind C-c run "tmux save-buffer - | pbcopy-remote"
# bind C-v run "tmux set-buffer $(pbpaste-remote); tmux paste-buffer"
#
# typing words in multiple panes
bind -n C-q set-window-option synchronize-panes\; display-message "synchronize-panes is now #{?pane_synchronized,on,off}"
# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
run -b '~/.tmux/plugins/tpm/tpm'