aboutsummaryrefslogtreecommitdiff
path: root/env/.config/tmux/tmux.conf
blob: a61d679adfc60fc68bfa8f9dd7ec5255046021ef (plain)
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
#run-shell ~/clone/path/logging.tmux
set -g default-terminal "screen-256color"
set -g terminal-overrides 'screen*:colors=256'

set -gq allow-passthrough on
set -g visual-activity off

#set -g status-interval 3

unbind C-b
set-option -g prefix C-space

# set vim mode
set-window-option -g mode-keys vi
setw -g mode-keys vi

# yank and visual rebinds
bind -T copy-mode-vi v send-keys -X begin-selection
bind -T copy-mode-vi y send-keys -X copy-pipe-and-cancel 'xclip -selection clipboard'

# dont exit copy mode with mouse drag
unbind -T copy-mode-vi MouseDragEnd1Pane


# bind r to reload config
unbind r
bind r source-file ~/.config/tmux/tmux.conf

# start panes and windows 1
set -g base-index 1
set -g pane-base-index 1
setw -g pane-base-index 1
set -g renumber-windows on # renumber windows when one is closed

# nav rebinds
bind -r C-h select-pane -L
bind -r C-j select-pane -D
bind -r C-k select-pane -U
bind -r C-l select-pane -R

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
bind -r m resize-pane -Z # maximize

# pane joining
bind J switch-client -T pane-management
bind-key -T pane-management % command-prompt -p "join pane from:"  "join-pane -s '%%' -h"
bind-key -T pane-management H command-prompt -p "join pane from:"  "join-pane -s '%%' -f -h"
bind-key -T pane-management \" command-prompt -p "join pane from:"  "join-pane -s '%%' -v"
bind-key -T pane-management V command-prompt -p "join pane from:"  "join-pane -s '%%' -f -v"
bind-key -T pane-management B break-pane
bind-key -T pane-management S command-prompt -p "send pane to:"  "join-pane -t '%%'"

bind-key -r H split-window -h -f


# colors/theme
# using vars in this cause the  chars to not use the color
set -g status-bg "#1a1b26"
set -g status-fg "#f1f1f1"
set -wg mode-style bg="#1a1b26"
set -g pane-border-style fg='#1a1b26'
set -g pane-active-border-style fg='#a030f0'
active_window_fg='#e080f0'
set -g status-left "#[fg=#f1f1f1,bold,bg=#4020af]  #S #[fg=#4020af,bg=#1a1b26] "
set -g status-left-length 40
set -g window-status-current-format "#[fg=${active_window_fg},bg=#1a1b26]#I:#W #[fg=#f1f1f1,bg=#1a1b26]"
set -g window-status-format "#[fg=#f1f1f1,bg=#1a1b26]#I:#W #[fg=#f1f1f1,bg=#1a1b26]"
set -g status-right '#[fg=#f1f1f1,bg=#4020af] @#H %H:%M %d-%b-%y'