-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.tmux.conf
101 lines (81 loc) · 3.28 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
# Use high-res colours
set -g default-terminal "tmux-256color"
set -ga terminal-overrides ",*256col*:Tc"
# Enable 'dim' colours
set -as terminal-overrides ',*:dim=\E[2m'
# Use default shell prompt
set-option -g default-command bash
set -sg escape-time 5
# Rebind the prefix key
set-option -g prefix C-p
set-option -g prefix2 C-Space
unbind-key C-p
unbind-key C-Space
bind-key C-p send-prefix
bind-key C-Space send-prefix -2
# Enable focus events
set-option -g focus-events on
# Set the escape time
set-option -sg escape-time 10
# Set window and pane numbering to start at 1 (not 0)
set -g base-index 1
set -g pane-base-index 1
set-window-option -g pane-base-index 1
set-option -g renumber-windows on
# Enable mouse to scroll through buffer history and select text
set -g mouse on
# Set background colour of active and inactive panes
# set-window-option -g window-active-style fg=terminal,bg=terminal
set-window-option -g window-active-style fg=terminal,bg=terminal
set-window-option -g window-style fg=terminal,bg=terminal
# Set vi-mode
set-window-option -g mode-keys vi
# Rebind keys for selecting text in copy mode
bind-key -T copy-mode-vi v send-keys -X begin-selection
bind-key -T copy-mode-vi C-v send-keys -X rectangle-toggle
bind-key -T copy-mode-vi y send-keys -X copy-pipe-and-cancel 'xclip -in -selection clipboard'
# Rebind keys for splitting panes + open split panes at current directory
bind '-' split-window -v -c '#{pane_current_path}'
bind '|' split-window -h -c '#{pane_current_path}'
# Bind key for launching tmux-sessionizer
bind-key -r f run-shell "tmux neww ~/.local/bin/tmux-sessionizer"
# Don't detach on session destroy (when destroyed, go to next active session)
set -g remain-on-exit on
set -g pane-died 'if -F "#{&&:#{==:#{session_windows},1},#{==:#{window_panes},1}}" "killp; detach" "killp"'
set-option -g detach-on-destroy off
# Catppuccin settings
set -g @catppuccin_window_tabs_enabled on
set -g @catppuccin_left_separator "█"
set -g @catppuccin_right_separator "█"
# set -g @catppuccin_date_time "%a %Y-%m-%d %H:%M"
# set -g @catppuccin_date_time "%Y-%m-%d %H:%M"
set -g @catppuccin_date_time "off"
set -g @catppuccin_host "off"
set -g @catppuccin_user "off"
set -g @catppuccin_wt_enabled "off"
# set -g @catppuccin_datetime_icon "•"
set -g @catppuccin_datetime_icon " "
set -g @catppuccin_user_icon ""
# Prefix highlight setting
# set -g status-left '#{prefix_highlight} | %a %Y-%m-%d %H:%M'
# Session persistence settings
set -g @resurrect-capture-pane-contents 'on'
set -g @continuum-restore 'on'
# set -g @continuum-boot 'on'
set -g @resurrect-strategy-nvim 'session'
set -g @resurrect-capture-pane-contents 'on'
# Plugins (after adding press Prefix-I to install)
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-sensible'
set -g @plugin 'christoomey/vim-tmux-navigator'
set -g @plugin 'tmux-plugins/vim-tmux-focus-events'
set -g @plugin 'tmux-plugins/tmux-yank'
set -g @plugin 'ofirgall/tmux-window-name'
set -g @plugin 'tmux-plugins/tmux-prefix-highlight'
set -g @plugin 'tmux-plugins/tmux-pain-control'
set -g @plugin 'jacobwardio/catppuccin-tmux'
set -g @plugin 'tmux-plugins/tmux-resurrect'
set -g @plugin 'tmux-plugins/tmux-continuum'
set -g @plugin 'wfxr/tmux-fzf-url'
# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
run '~/.tmux/plugins/tpm/tpm'