-
Notifications
You must be signed in to change notification settings - Fork 0
/
.tmux.conf
93 lines (82 loc) · 2.45 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
# Prefix binding {{{
set -g prefix C-g
unbind C-b
bind g send-prefix
bind-key C-g last-window
# }}}
# General {{{
set -sg escape-time 0
setw -g aggressive-resize off
bind R source-file ~/.tmux.conf \; display-message " ↻ tmux.conf"
bind q kill-window
set -g default-terminal "xterm-256color"
set -ga terminal-overrides ",xterm-256color:Tc"
# Auto renumber windows
set-option -g renumber-windows on
# }}}
# Status bar {{{
set -g status-bg colour7
set -g status-fg colour12
set -g status-left-length 40
set -g status-right-length 40
set -g status-left '#[bg=cyan,fg=white]#{?client_prefix,#[bg=colour1] ⌘ , 🔥 } #S #[default]'
set -g status-right '#(cat ~/.current_ts)#[bg=colour2,fg=white] #h · #(date "+%H:%M") '
set -g status-position 'top'
set -g base-index 1
set -g status-justify centre
set-window-option -g pane-base-index 1
set-window-option -g window-status-fg colour239
set-window-option -g window-status-bg colour7
# window format {{{
setw -g window-status-format '#[fg=colour12,noreverse] #I·#[default,noreverse]#{?window_zoomed_flag,[[ #W ]],#W} '
setw -g window-status-current-format '#[fg=colour2,bg=colour15] ●#[fg=colour250] #[fg=cyan,bg=colour15]#{?window_zoomed_flag,[[ #W ]],#W} '
# }}}
# }}}
# Set window notifications {{{
setw -g monitor-activity on
set -g visual-activity on
# Automatically set window title
# setw -g automatic-rename
set-option -g allow-rename off
# }}}
# window management {{{
unbind %
unbind s
bind | split-window -h
bind _ split-window -v
bind-key S command-prompt "attach-session -t '%%'"
bind-key s choose-session
bind » next-window
bind « previous-window
#link shared:ts
bind T link-window -s shared:ts
# }}}
# Vi style bindings {{{
setw -g mode-keys vi
unbind Escape
unbind -Tcopy-mode-vi Space
unbind -Tcopy-mode-vi Enter
bind -Tcopy-mode-vi v send -X begin-selection
bind -Tcopy-mode-vi y send -X copy-selection
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
# bind-key Y run-shell "tmux save-buffer - | reattach-to-user-namespace pbcopy"
bind-key Y run-shell "tmux save-buffer - | xsel -i -b"
# }}}
# Resizing {{{
bind < resize-pane -L 15
bind > resize-pane -R 15
bind - resize-pane -D 15
bind + resize-pane -U 15
# }}}
# Misc {{{
bind o run ~/.dotfiles/tmux-url-select/tmux-url-select.pl
# }}}
# Plugins {{{
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-sensible'
set -g @plugin 'tmux-plugins/tmux-resurrect'
set -g @plugin 'tmux-plugins/tmux-continuum'
# }}}