-
Notifications
You must be signed in to change notification settings - Fork 0
/
.tmux.conf
91 lines (70 loc) · 2.39 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
# keymap for resource config
unbind r
bind r source-file ~/.tmux.conf
# enable true color
set -g default-terminal "tmux-256color"
set -ag terminal-overrides ",xterm-256color:RGB"
# remap prefix
set -g prefix C-s
unbind C-b
bind-key C-s send-prefix
# remap split pane
unbind %
bind | split-window -h
unbind '"'
bind _ split-window -v
bind -r m resize-pane -Z
set -g mouse on
set -g status-position top
# Vim motion
set-window-option -g mode-keys vi
bind-key -T copy-mode-vi 'v' send -X begin-selection
bind-key -T copy-mode-vi 'y' send -X copy-selection
unbind -T copy-mode-vi MouseDragEnd1Pane
# Turn on Xterm Keys for modifier keys pass through
set -s extended-keys on
set-option -g xterm-keys on
set -as terminal-features 'xterm*:extkeys'
# fuzzy find tmux session
bind-key S run-shell -b "~/.tmux/tmux-switch-session.sh"
# reindexing for easier navigation
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
# optimization for nvim
set-option -sg escape-time 10
set-option -g focus-events on
# List of plugins
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'christoomey/vim-tmux-navigator'
# theme
set -g @plugin 'catppuccin/tmux#latest'
set -g @catppuccin_flavor 'mocha'
set -g @catppuccin_window_left_separator ""
set -g @catppuccin_window_right_separator " "
set -g @catppuccin_window_middle_separator " █"
set -g @catppuccin_window_number_position "right"
set -g @catppuccin_window_default_fill "number"
set -g @catppuccin_window_default_text "#W"
set -g @catppuccin_window_current_fill "number"
set -g @catppuccin_window_current_text "#W"
set -g @catppuccin_status_modules_left "session"
set -g @catppuccin_status_modules_right "application host"
set -g @catppuccin_status_left_separator " "
set -g @catppuccin_status_right_separator ""
set -g @catppuccin_status_fill "icon"
set -g @catppuccin_status_connect_separator "no"
set -g @catppuccin_directory_text "#{pane_current_path}"
# Yazi image preview setup
set -g allow-passthrough on
set -ga update-environment TERM
set -ga update-environment TERM_PROGRAM
# Session resurrect
set -g @plugin 'tmux-plugins/tmux-resurrect'
set -g @plugin 'tmux-plugins/tmux-continuum'
set -g @resurrect-save 'C-w'
set -g @resurrect-capture-pane-contents 'on'
set -g @continuum-restore 'on'
# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
run '~/.tmux/plugins/tpm/tpm'