aboutsummaryrefslogtreecommitdiff
path: root/.config/tmux/tmux.conf
blob: a9440d98c0d32828e714de3e0d09cdfa565b5430 (plain)
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
# set default shell
set -g default-command "${SHELL}"

# set prefix to ctrl+a
set -g prefix C-a
bind C-a send-prefix
unbind C-b

# settings
set -g mouse on
set -g status off
set -g base-index 1
set -g mode-keys vi
set -sg escape-time 1
set -g visual-activity on
set -g history-limit 10000
setw -g monitor-activity on
setw -g pane-base-index 1

# border colours
set -g pane-border-style fg=colour0
set -g pane-active-border-style fg=colour0

# y and p as in vim
bind Escape copy-mode
unbind p
bind p paste-buffer
bind-key -T copy-mode-vi 'v' send -X begin-selection
bind-key -T copy-mode-vi 'y' send -X copy-selection
bind-key -T copy-mode-vi 'Space' send -X halfpage-down
bind-key -T copy-mode-vi 'Bspace' send -X halfpage-up

# easy-to-remember split pane commands
bind | split-window -h
bind - split-window -v
unbind '"'
unbind %

# moving between panes with vim movement keys
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R

# moving between windows with vim movement keys
bind -r C-h select-window -t :-
bind -r C-l select-window -t :+

# resize panes with vim movement keys
bind -r H resize-pane -L 5
bind -r J resize-pane -D 5
bind -r K resize-pane -U 5
bind -r L resize-pane -R 5