b772566bddff4cc9e237947a02bbd775b9867960
[dotfiles.git] / shell / .config / tmux / config
1 # prefix
2 unbind C-b
3 set-option -g prefix C-a
4 bind C-a send-prefix
5
6 # hjkl pane traversal
7 bind h select-pane -L
8 bind j select-pane -D
9 bind k select-pane -U
10 bind l select-pane -R
11
12 # i3 window splitting
13 unbind %
14 unbind '"'
15 bind V split-window -v
16 bind H split-window -h
17
18 # Start not at index 0 but at one for windows
19 set -g base-index 1
20
21 # vi copy and pasting
22 bind-key -T copy-mode-vi 'v' send -X begin-selection
23 bind-key -T copy-mode-vi 'y' send -X copy-selection
24 bind-key -T copy-mode-vi 'Space' send -X halfpage-down
25 bind-key -T copy-mode-vi 'Bspace' send -X halfpage-up
26
27 # urlview
28 bind-key u capture-pane \; \
29 run-shell "st -e sh -c 'tmux save-buffer - | urlview'"
30
31 # interactive panel to other windows
32 bind-key M choose-tree -Zw "join-pane -t '%%'"
33
34 # interactive panel to other session
35 bind-key C-m choose-tree -Zs "join-pane -t '%%'"