-
Notifications
You must be signed in to change notification settings - Fork 1
/
.tmux.conf
85 lines (71 loc) · 2.36 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
# Increase scroll back buffer
set-option -g history-limit 5000
# make windows start at index 1 so ist easier to switch between them
set -g base-index 1
# remap prefix from 'C-b' to 'C-a'
unbind C-b
set-option -g prefix C-a
bind-key C-a send-prefix
# split panes using | and -
bind | split-window -h
bind - split-window -v
unbind '"'
unbind %
# reload config file (change file location to your the tmux.conf you want to use)
bind r if-shell "test -r $HOME/.tmux.conf" "source $HOME/.tmux.conf" \; display "Reloaded $HOME/.tmux.conf"
# switch panes using Alt-arrow without prefix
bind -n M-Left select-pane -L
bind -n M-Down select-pane -D
bind -n M-Up select-pane -U
bind -n M-Right select-pane -R
# also vim like keys
bind -n M-h select-pane -L
bind -n M-j select-pane -D
bind -n M-k select-pane -U
bind -n M-l select-pane -R
# Resize vim like
bind -n M-y resize-pane -L 5
bind -n M-u resize-pane -D 5
bind -n M-i resize-pane -U 5
bind -n M-o resize-pane -R 5
# window switching
bind -n M-Pagedown next-window
bind -n M-Pageup previous-window
bind -n M-C-a last-window
# old style switching
bind -n M-C-Left previous-window
bind -n M-C-Right next-window
# also vim like keys
bind -n M-C-h previous-window
bind -n M-C-l next-window
# Last pane/window with ctrl-tab et al
#bind -n M-C-Tab last-window # Does not seem to work :(
#bind -n C-Tab last-pane # Does not seem to work :(
# Enable mouse mode (tmux 2.1 and above)
# set -g mouse on
set -g mouse off
#set -g mouse-select-pane on
# Enable mouse mode (prior to tmux 2.1)
# setw -g mode-mouse on
# set -g mouse-select-window on
# set -g mouse-select-pane on
# #set -g mouse-resize-pane on
# set -g mouse-utf on
# Fix some mouse scroll behaviour
#bind -n WheelUpPane copy-mode
# Enter scroll mode
# Use space/v to start selection, then enter/y to make a copy to the clipboard
# To paste, use shift+ins or C-a ]
bind C-s copy-mode
# and do it in vi like mode
set-window-option -g mode-keys vi
bind-key -T copy-mode-vi 'v' send -X begin-selection
bind-key -T copy-mode-vi 'y' send -X copy-selection-and-cancel
set -g set-clipboard on # Let any application create tmux paste buffers (including nested tmux'es)
# True-color mode
set -g default-terminal "linux"
set-option -ga terminal-overrides ",xterm-256color:Tc"
######################
### DESIGN CHANGES ###
######################
if-shell "test -r $HOME/.tmux.theme" "source $HOME/.tmux.theme"