-
Notifications
You must be signed in to change notification settings - Fork 0
/
.tmux.conf
63 lines (48 loc) · 1.78 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
# Vi mode-keys
set-window-option -g mode-keys vi
# Vi visual mode
bind-key -T copy-mode-vi 'v' send -X begin-selection
bind-key -T copy-mode-vi 'y' send -X copy-selection-and-cancel
bind-key -T copy-mode-vi 'Escape' send -X cancel
# Enables mouse for scrolling
set -g mouse on
# Enable colors
set -g default-terminal "xterm-256color"
# Nvim colors and ESC delay
set -ga terminal-overrides ",*256col*:Tc"
set -sg escape-time 0
# Enables Prefix indicator in status bar
set -g status-right ' #{?client_prefix,#[reverse]<Prefix>#[noreverse] ,}"#{=21:pane_title}" %H:%M %d-%b-%y'
# Remap prefix to C-Space
unbind C-b
set -g prefix C-Space
bind C-Space send-prefix
# Split panes using | and -
bind \\ split-window -h -c "#{pane_current_path}"
bind - split-window -v -c "#{pane_current_path}"
unbind '"'
unbind \%
# Reload config file (change file location to your the tmux.conf you want to use)
bind r source-file ~/.tmux.conf \; display-message ".tmux.conf reloaded."
# Use vim-like keys for splits
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
# Kill pane without confirm
bind x kill-pane
# Disable cancel on copy mouse drag & pipe to system clipboard
bind-key -T copy-mode MouseDragEnd1Pane send-keys -X copy-pipe "xclip -in -selection clipboard"
# Move windows
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
# List of plugins
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-resurrect'
set -g @plugin 'tmux-plugins/tmux-continuum'
set -g @plugin 'tmux-plugins/tmux-copycat'
# Plugin settings
set -g @continuum-restore 'on'
set -g @resurrect-processes ':all:'
# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
run '~/.tmux/plugins/tpm/tpm'