-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.tmux.conf
93 lines (73 loc) · 3.8 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
# default statusbar color
set-option -g status-style bg=colour237,fg=colour223 # bg=bg1, fg=fg1
# default window title colors
set-window-option -g window-status-style bg=colour214,fg=colour237 # bg=yellow, fg=bg1
# default window with an activity alert
set-window-option -g window-status-activity-style bg=colour237,fg=colour248 # bg=bg1, fg=fg3
# # active window title colors
# set-window-option -g window-status-current-style bg=red,fg=colour237 # fg=bg1
# pane border
set-option -g pane-active-border-style fg=colour250 #fg2
set-option -g pane-border-style fg=colour237 #bg1
# message infos
set-option -g message-style bg=colour239,fg=colour223 # bg=bg2, fg=fg1
# writing commands inactive
set-option -g message-command-style bg=colour239,fg=colour223 # bg=fg3, fg=bg1
# pane number display
set-option -g display-panes-active-colour colour250 #fg2
set-option -g display-panes-colour colour237 #bg1
# clock
set-window-option -g clock-mode-colour colour109 #blue
# bell
set-window-option -g window-status-bell-style bg=colour167,fg=colour235 # bg=red, fg=bg
## Theme settings mixed with colors (unfortunately, but there is no cleaner way)
set-option -g status-justify "left"
set-option -g status-left-style none
set-option -g status-left-length "80"
set-option -g status-right-style none
set-option -g status-right-length "80"
set-window-option -g window-status-separator ""
set-option -g status-left "#[fg=colour248, bg=colour241] #S #[fg=colour241, bg=colour237, nobold, noitalics, nounderscore]"
set-option -g status-right "#[fg=colour239, bg=colour237, nobold, nounderscore, noitalics]#[fg=colour246,bg=colour239] %m-%d %H:%M UTC #(date -u +"%%H:%%M") #[fg=colour248, bg=colour239, nobold, noitalics, nounderscore]#[fg=colour237, bg=colour248] #h "
set-window-option -g window-status-current-format "#[bg=colour214,fg=colour237,nobold,noitalics,nounderscore]#[bg=colour214,fg=colour239] #I #[bg=colour214,fg=colour239,bold] #W#{?window_zoomed_flag,*Z,} #[bg=colour237,fg=colour214,nobold,noitalics,nounderscore]"
set-window-option -g window-status-format "#[bg=colour239,fg=colour237,noitalics]#[bg=colour239,fg=colour223] #I #[bg=colour239,fg=colour223] #W #[bg=colour237,fg=colour239,noitalics]"
#### CUSTOM ###
set -g base-index 1 # Start numbering at 1
## vim-like configs
set-window-option -g mode-keys vi
# splits like vim
bind-key v split-window -h -c "#{pane_current_path}"
bind-key s split-window -v -c "#{pane_current_path}"
# resizes like vim
bind-key -r H resize-pane -L "2"
bind-key -r J resize-pane -D "2"
bind-key -r K resize-pane -U "2"
bind-key -r L resize-pane -R "2"
# moves like vim
bind-key h select-pane -L
bind-key C-h select-pane -L
bind-key j select-pane -D
bind-key C-j select-pane -D
bind-key k select-pane -U
bind-key C-k select-pane -U
bind-key l select-pane -R
bind-key C-l select-pane -R
# popup config, only available 3.1 and onwards
bind-key -n ` if '[ "#{session_name}" = "_popup" ]' \
'detach' \
'display-popup -E -h 90% -w 90% tmux new-session -A -s _popup -c "#{pane_current_path}"'
## reload config
bind-key R source-file ~/dot-me-up/.tmux.conf \; display-message "source-file done"
## copy paste
bind-key -T copy-mode-vi v send-keys -X begin-selection
bind-key -T copy-mode-vi y send-keys -X copy-selection
## toggle status visibility
# bind-key a set-option -g status
bind-key n choose-tree -s -Z # choose session
set-option -s escape-time 0 # vim <esc> delay solution
set-option -g history-limit 50000 # increase scrollback history
set-option -g display-time 4000 # tmux messages display for 4s
set-option -g focus-events on # neovim advice
set-option -g default-terminal "screen-256color" # neovim advice
set-option -a terminal-overrides 'xterm-256color:Tc' # neovim advice
bind-key c new-window -c "#{pane_current_path}" # new pane directory defaults to current one