-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathtmux-31.conf
82 lines (82 loc) · 3.54 KB
/
tmux-31.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
## Use ~ for prefix
set -g prefix `
bind ` send-key `
# Change the prefix key to C-a
set -g prefix C-a
unbind C-b
bind C-a send-prefix
## Not stupid keys for splitting panes
bind-key - split-window -v
bind-key _ split-window -v
bind-key \\ split-window -h
bind-key | split-window -h
## Keybinds for murdering unresponsive panes
bind-key x confirm-before kill-pane
bind-key X confirm-before kill-window
## Let us live-reload our config
bind r source-file ~/.tmux.conf
## Starts windows and panes at 1 not 0, because 0 is obnoxious
set-option -g base-index 1
set-option -g pane-base-index 1
## set status bar color, and add our name / server to the right
set-option -g status-bg colour22
set-option -g status-fg colour15
set-option -g status-left ' #[bold]❐ #S#[default] ⡇'
set-option -g status-right '#[bold]#(whoami) ● #H#[default] '
set-option -g status-right-length 60
set-option -g status-left-length 60
## highlight active window on status bar
set-window-option -g window-status-current-style bg=colour46,fg=colour235,bold
set-window-option -g window-status-current-format ' #I #W '
## set window notifications
set-option -g visual-activity on
set-window-option -g monitor-activity on
set-window-option -g automatic-rename off
set-window-option -g window-status-activity-style bg=colour15,fg=colour235
## tmux window titling for X
set-option -g set-titles on
set-option -g set-titles-string '[#I] #W'
set-window-option -g automatic-rename on
set-window-option -g window-status-format ' #I #W '
set-window-option -g pane-base-index 1
set-window-option -g renumber-windows 1
## pane border and colors
set-option -g pane-active-border-style fg=colour46
set-option -g pane-border-style fg=colour235
## enable mouse
set-window-option -g mode-keys vi
set-window-option -g mouse on
#Test New Tmux 3.1c with pugins
#tmux continumm and tmux ressucrect configuration and plugins
set -g @plugin '~/tmux-plugins/tmux-resurrect'
set -g @plugin '~/tmux-plugins/tmux-continuum'
set -g @resurrect-capture-pane-contents 'on'
set -g @resurrect-processes 'ssh psql mysql sqlite3 cf nano'
set -g @continuum-restore 'on'
###testing
set -g @continuum-save-interval '3'
# disable mouse control by default - change 'off' to 'on' to enable by default.
bind M set -g mouse on
bind m set -g mouse off
#copy paste without mouse
# Linux only copy paste in shell
set -g mouse on
#bind -n WheelUpPane if-shell -F -t = "#{mouse_any_flag}" "send-keys -M" "if -Ft= '#{pane_in_mode}' 'sen$
bind -n WheelDownPane select-pane -t= \; send-keys -M
bind -n C-WheelUpPane select-pane -t= \; copy-mode -e \; send-keys -M
bind -T copy-mode-vi C-WheelUpPane send-keys -X halfpage-up
bind -T copy-mode-vi C-WheelDownPane send-keys -X halfpage-down
bind -T copy-mode-emacs C-WheelUpPane send-keys -X halfpage-up
bind -T copy-mode-emacs C-WheelDownPane send-keys -X halfpage-down
# To copy, left click and drag to highlight text in yellow,
# once you release left click yellow text will disappear and will automatically be available in clibboa$
# # Use vim keybindings in copy mode
setw -g mode-keys vi
# Update default binding of `Enter` to also use copy-pipe
unbind -T copy-mode-vi Enter
bind-key -T copy-mode-vi Enter send-keys -X copy-pipe-and-cancel "xclip -selection c"
bind-key -T copy-mode-vi MouseDragEnd1Pane send-keys -X copy-pipe-and-cancel "xclip -in -selection clip$
set -g mouse on
# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
run-shell ~/.tmux/plugins/tmux-resurrect/resurrect.tmux
run '~/.tmux/plugins/tpm/tpm'