-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.tmux.conf
116 lines (90 loc) · 3.37 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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
set -g default-shell /bin/bash
set -g default-terminal "xterm-256color"
set-option -ga terminal-overrides ",xterm-256color:Tc"
set -g history-limit 9000 # scrollback buffer n lines
set -g status-position bottom # top
set -g status-interval 1
unbind C-b
unbind C-p
unbind C-Space
set -g prefix C-Space
bind Space send-prefix
# bind to reload config
bind r source-file ~/.tmux.conf \; display-message "Config reloaded."
set -sg escape-time 1
set -g base-index 1
setw -g pane-base-index 1
# toggle mouse mode to allow mouse copy/paste
# set mouse on with prefix m
bind m set-option -g mouse on\; display-message 'Mouse: ON'
# set mouse off with prefix M
bind M set-option -g mouse off\; display-message 'Mouse: OFF'
setw -g monitor-activity off
set -g visual-activity off
set-window-option -g mode-keys vi
set -g mode-keys vi
set -g status-keys vi
# y and p as in vim
unbind ]
unbind p
bind Escape copy-mode \; display-message "Copy mode..."
bind p paste-buffer
bind-key -T copy-mode-vi v send-keys -X begin-selection
# bind-key -T copy-mode-vi y send-keys -X copy-pipe-and-cancel "wl-copy -op"
bind-key -T copy-mode-vi y send-keys -X copy-pipe-and-cancel "xclip"
# key bindings for horizontal and vertical panes
unbind %
unbind '"'
bind | split-window -h
bind - split-window -v
# moving between panes with vim movement keys
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
# moving between windows with vim movement keys
bind -r C-h select-window -t :-
bind -r C-l select-window -t :+
# resize panes with vim movement keys
bind -r H resize-pane -L 5
bind -r J resize-pane -D 5
bind -r K resize-pane -U 5
bind -r L resize-pane -R 5
# start window indexing at one instead of zero
set -g base-index 1
bind s set -g synchronize-panes
setw -g automatic-rename
setw -g monitor-activity on
set -g visual-activity on
# enable window titles
set -g set-titles on
set-option -g status-justify left
set-option -g status-right " ▶ #S⁄#(tmux ls|wc -l|tr -d ' ') ⋮ ■ #I⁄#(tmux lsw|wc -l|tr -d ' ') ⋮ ◨ #(tmux lsp -F '#F' | grep -q Z&& echo ^|tr -d ' ')#(tmux lsp|grep active|cut -d ':' -f 1|tr -d ' ')⁄#(tmux lsp -F '#F'|wc -l|tr -d ' ') ⋮ ⇄ #{pane_synchronized} ⋮ #(date +"%I:%M") "
set-window-option -g status-left " 🔒⋮ "
set-option -g status-right-length 50
set-option -g status-left-length 50
set -g status on
set-window-option -g window-status-format " #I "
set-window-option -g window-status-current-format " #I "
bind-key b command-prompt -p "join pane from:" "join-pane -s '%%'"
bind-key B command-prompt -p "send pane to:" "join-pane -t '%%'"
### COLOUR
# default mode colors
set -g mode-style 'bg=colour249,fg=colour255'
# default statusbar colors
set -g status-style 'bg=colour253,fg=colour0'
set -g status-left-style 'bg=colour253,fg=colour0'
set -g status-right-style 'bg=colour253,fg=colour0'
# default window title colors
set -g window-status-current-style 'bg=colour253,fg=colour0'
# active window title colors
set -g window-status-current-style 'bg=colour255,fg=colour240'
# pane border
set-option -g pane-active-border-style 'bg=colour255,fg=colour244'
set-option -g pane-border-style 'bg=colour255,fg=colour244'
# message text
set -g message-style 'bg=colour255,fg=colour240'
# pane number display
set-option -g display-panes-active-colour blue
set-option -g display-panes-colour brightred
set -g pane-active-border-style 'bg=colour254,fg=colour0'