-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathtmux.conf
88 lines (69 loc) · 2.63 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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
set -g prefix C-j
setw -g mode-keys vi
set -g history-limit 32768
set -g default-terminal "screen-256color"
set-option -g automatic-rename on
# do not clear terminal text when vim launches
set-window-option -g alternate-screen on
# window resizing per-client
set-window-option -g aggressive-resize on
# only display bell for activity
set -g visual-activity off
# open/split window with the same path as the current one
bind c new-window -c "#{pane_current_path}"
bind '"' split-window -c "#{pane_current_path}"
bind % split-window -h -c "#{pane_current_path}"
# disable escape key delay
set -g escape-time 0
## KEYBINDINGS
# r = renumber windows
unbind r
bind r run "~/.dotfiles/bin/tmux-renum"
# Ctrl+V - zoom current pane in/out
bind C-v run "~/.dotfiles/bin/tmux-zoom"
# t = swap with given window
unbind t
bind-key t command-prompt -p "move to:" "swap-window -t '%%'"
# vi-style selection
# bind-key -t vi-copy 'v' begin-selection
# bind-key -t vi-copy 'y' copy-selection
bind-key -Tcopy-mode-vi 'v' send -X begin-selection
bind-key -Tcopy-mode-vi 'y' send -X copy-selection
# rebound layouts and pane selection
bind-key M-0 select-pane -t 0
bind-key M-1 select-pane -t 1
bind-key M-2 select-pane -t 2
bind-key M-3 select-pane -t 3
bind-key M-4 select-pane -t 4
bind-key M-5 select-pane -t 5
bind-key 'M-!' select-layout even-horizontal
bind-key 'M-@' select-layout even-vertical
bind-key 'M-#' select-layout main-horizontal
bind-key 'M-$' select-layout main-vertical
bind-key 'M-%' select-layout tiled
# quick zoom of another pane
bind-key k select-pane -t :.+ \; resize-pane -Z \; copy-mode
unbind \;
bind-key \; resize-pane -Z \; select-pane -t :.+
# OS-specific configs, for clipboard buffer etc
if-shell 'test "$(uname)" = "Linux"' 'source ~/.dotfiles/tmux/tmux-linux.conf'
if-shell 'test "$(uname)" = "Darwin"' 'source ~/.dotfiles/tmux/tmux-osx.conf'
# battery charge indicator in the status line
set -g status-right "#(~/.dotfiles/bin/battery Discharging; ~/.dotfiles/bin/battery Charging) | %e %b %R"
# Solarized light color scheme
# default statusbar colors
set-option -g status-style bg=white,fg=yellow
# default window title colors
set-window-option -g window-status-style bg=default,fg=brightyellow
# active window title colors
set-window-option -g window-status-current-style bg=colour12,fg=white
# pane border
set-option -g pane-border-style fg=white
set-option -g pane-active-border-style fg=brightcyan
# message text
set-option -g message-style bg=white,fg=brightred
# pane number display
set-option -g display-panes-active-colour blue #blue
set-option -g display-panes-colour brightred #orange
# clock
set-window-option -g clock-mode-colour green #green