-
Notifications
You must be signed in to change notification settings - Fork 3
/
tmux.conf
56 lines (43 loc) · 1.79 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
set -g prefix C-q
# Don't pause for Esc
set -g escape-time 0
# Enable 24-bit true color.
set -ga terminal-overrides ",xterm-256color:Tc"
set -ga terminal-overrides ",alacritty:Tc"
run-shell ~/dotfiles/tmux/sensible/sensible.tmux
run-shell ~/dotfiles/tmux/yank/yank.tmux
source-file ~/dotfiles/tmux/solarized/tmuxcolors-light.conf
# Vi key bindings
set-window-option -g mode-keys vi
# No need for a busy status line.
set -g status-right ""
# automatically renumber after closing windows
set-option -g renumber-windows on
# Start numbering windows and panes from 1 instead of 0.
set -g base-index 1
set-window-option -g pane-base-index 1
set-option -g mouse on
bind-key -T root PPage if-shell -F "#{alternate_on}" "send-keys PPage" "copy-mode -u -e"
# no-op PageDown in regular mode to keep tildes from showing up in the shell
bind-key -T root NPage if-shell -F "#{alternate_on}" "send-keys NPage" "run-shell true"
# Open new panes in the working dir of the current pane.
bind c new-window -c '#{pane_current_path}'
bind '"' split-window -c '#{pane_current_path}'
bind % split-window -h -c '#{pane_current_path}'
# Make <prefix>C-o the same as <prefix>o, because I hit it all the time.
bind C-o select-pane -t :.+
# Custom bindings. Follow the tmux-sensible pattern of binding both [key] and
# Ctrl-[key] for easy chaining with the prefix.
bind-key h select-pane -L
bind-key C-h select-pane -L
bind-key j select-pane -D
bind-key C-j select-pane -D
bind-key k select-pane -U
bind-key C-k select-pane -U
bind-key l select-pane -R
bind-key C-l select-pane -R
bind-key - split-window -c '#{pane_current_path}'
bind-key '\' split-window -h -c '#{pane_current_path}'
# Window reordering bindings from https://superuser.com/a/552493/93400.
bind-key -n C-S-Left swap-window -t -1 -d
bind-key -n C-S-Right swap-window -t +1 -d