This repository has been archived by the owner on Mar 10, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
tmux.conf
92 lines (70 loc) · 2.82 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
89
90
91
92
set -g default-terminal "screen-256color"
set -gs escape-time 0
set -g history-limit 99999
### Base keybindings
unbind-key c
bind-key c new-window -c "#{pane_current_path}"
set -g mouse on
#### COLOUR (Solarized dark)
set -g @plugin 'jimeh/tmux-themepack'
set -g @themepack 'powerline/block/blue'
set -g @plugin 'tmux-plugins/tmux-yank'
set -g @plugin 'tmux-plugins/tmux-sensible'
# default statusbar colors
#set-option -g status-bg black #base02
#set-option -g status-fg yellow #yellow
#set-option -g status-attr default
# default window title colors
#set-window-option -g window-status-fg brightblue #base0
#set-window-option -g window-status-bg default
#set-window-option -g window-status-attr dim
# active window title colors
#set-window-option -g window-status-current-fg brightred #orange
#set-window-option -g window-status-current-bg default
#set-window-option -g window-status-current-attr bright
# pane border
#set-option -g pane-border-fg black #base02
#set-option -g pane-active-border-fg brightgreen #base01
# message text
#set-option -g message-bg black #base02
#set-option -g message-fg brightred #orange
# 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
set-window-option -g aggressive-resize on
set-option -g renumber-windows on
### Vim keybindings
setw -g mode-keys vi
# vim like visual selection in copy-mode (as well as mouse)
bind-key -T copy-mode-vi 'v' send -X begin-selection
# smart pane switching with awareness of vim splits
bind -n C-h run "(tmux display-message -p '#{pane_current_command}' | grep -iqE '(^|\/)n?vim(diff)?$|emacs.*$' && tmux send-keys C-h) || tmux select-pane -L"
bind -n C-j run "(tmux display-message -p '#{pane_current_command}' | grep -iqE '(^|\/)n?vim(diff)?$|emacs.*$' && tmux send-keys C-j) || tmux select-pane -D"
bind -n C-k run "(tmux display-message -p '#{pane_current_command}' | grep -iqE '(^|\/)n?vim(diff)?$|emacs.*$' && tmux send-keys C-k) || tmux select-pane -U"
bind -n C-l run "(tmux display-message -p '#{pane_current_command}' | grep -iqE '(^|\/)n?vim(diff)?$|emacs.*$' && tmux send-keys C-l) || tmux select-pane -R"
#toggle windows
bind ^B last-window
unbind-key %
bind-key v split-window -h -c "#{pane_current_path}"
unbind-key '"'
unbind-key s
bind-key s split-window -c "#{pane_current_path}"
bind-key '"' choose-session
unbind-key +
bind-key + resize-pane -D 5
unbind-key -
bind-key - resize-pane -U 5
unbind-key <
bind-key < resize-pane -L 5
unbind-key >
bind-key > resize-pane -R 5
# Stop tmux jumping to the bottom after selection
unbind -T copy-mode-vi MouseDragEnd1Pane
# bind-key C-l send-keys C-l
#bind-key C-l send-keys -R
new-session
# from https://github.com/tmux-plugins/tpm
# Install plugins with prefix+I
run '~/.tmux/plugins/tpm/tpm'