-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtmux.conf
More file actions
150 lines (113 loc) · 4.55 KB
/
Copy pathtmux.conf
File metadata and controls
150 lines (113 loc) · 4.55 KB
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
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
# remap prefix to C-z
set -g prefix C-x
unbind C-b
bind C-x send-prefix
# mouse scrolling and selection
set -g mouse off
#mode keys
setw -g mode-keys vi
# true color/256 colors terminal
set-option -a terminal-features 'xterm-256color:RGB'
set-option -g update-environment "SSH_AUTH_SOCK SSH_AUTH_PID SSH_CONNECTION DISPLAY"
# scroll limit
set -g history-limit 100000
# reload config without killing server
bind r source-file ~/.tmux.conf \; display-message " Config reloaded..."
##status
set -g status on
set -g status-interval 2
bind-key -n C-b set-window-option status
# faster response
set-option -sg escape-time 0
# enable focus events (if available)
set-option -g focus-event on
# swiching to last window like screen
bind-key C-z last-window
# send C-z-z sends C-z to the shell
bind-key z send-prefix
# xterm keys!
set-window-option -g xterm-keys on
# sane splitting
bind e split-window -h -c '#{pane_current_path}'
bind o split-window -v -c '#{pane_current_path}'
#bind -n C-E split-window -h
#bind -n C-O split-window -v
# nova janela com t/Ctrl-shift-t
bind t new-window -c '#{pane_current_path}'
#bind -n C-T new-window
# nova janela com Ctrl-shift-w
#bind -n C-W kill-window
# switch between windows Ctrl-[pagedown|pageup]
bind -n C-PageDown next-window
bind -n C-PageUp previous-window
bind l next-window
bind h previous-window
# move windows Ctrl-shift-[left|right]
bind-key -n C-S-Left swap-window -d -t -1
bind-key -n C-S-Right swap-window -d -t +1
bind -T copy-mode-vi y send-keys -X copy-pipe-and-cancel "xsel -i --clipboard"
# vi keys
set-option -g status-keys vi
#setw -g mode-keys vi
# usar Escape para entrar no modo copia,
# v para selecionar, p para colar,
# = para lista de buffer
unbind [
bind Escape copy-mode
bind -n M-Enter send-keys C-a 'sudo ' C-e
bind -n M-p send-keys 'pacman '
bind -n M-z resize-pane -Z
bind -n M-m resize-pane -Z
# TPM Plugins
set -g @override_copy_command 'xsel -ip'
set -g @plugin 'tmux-plugins/tmux-resurrect'
set -g @plugin 'tmux-plugins/tmux-continuum'
set -g @plugin 'tmux-plugins/tmux-yank'
set -g @plugin 'christoomey/vim-tmux-navigator'
set -g @plugin 'thekylehuang/cole-tmux'
set -g @plugin 'nickdiego/tmux-pocket-pane'
# Plugins configs
set -g @resurrect-strategy-vim 'session'
set -g @resurrect-capture-pane-contents 'on'
set -g @resurrect-processes '~claude->claude'
#set -g @continuum-restore 'on'
#set -g @continuum-save-interval '5'
set -g @vim_navigator_mapping_left "M-h" # use C-h and C-Left
set -g @vim_navigator_mapping_right "M-l"
set -g @vim_navigator_mapping_up "M-k"
set -g @vim_navigator_mapping_down "M-j"
set -g @vim_navigator_mapping_prev "" # removes the C-\ binding
# Required to avoid issues with base16 themes.
set -g allow-passthrough 'on'
# Forward DECSCUSR cursor-shape changes to the outer terminal. Without this,
# tmux swallows cursor-style escape codes from inner programs (vim/nvim
# insert-vs-normal mode, etc.) since terminfo entries like xterm-ghostty
# don't define the Ss/Se capabilities tmux otherwise relies on.
set -ga terminal-overrides ',*:Ss=\E[%p1%d q:Se=\E[2 q'
# tmux's own Ss/Se passthrough doesn't reliably preserve the blink bit (it
# tends to flatten requests to steady), so assert the desired baseline
# shape+blink directly via tmux's native option instead of relying on
# whatever an inner program (or Ghostty's shell-integration) requested.
set -g cursor-style blinking-bar
set-environment -g TMUX_PLUGIN_MANAGER_PATH '~/.tmux/plugins/'
# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
run-shell '~/.tmux/plugins/tpm/tpm'
# Override plugin-set values after TPM init
set -g status-position bottom
set -g status-style bg=default
set -g status-right "#[fg=#f2e6cf] #H | %H:%M #[bg=#cc5d4b,fg=#121212,bold] %Y-%m-%d "
unbind -n C-l
# Toggle claude full-height right-side pane (100 columns) bound to M-a.
set -g @pocket-pane-claude-cmd 'claude'
set -g @pocket-pane-claude-layout '100,horizontal,full'
bind -n M-a run-shell "#{@pocket-pane-path}/pocket-pane.sh toggle claude"
# Toggle chromium sync/build bottom pane (30% width) bound to M-S-s.
set -g @pocket-pane-chrsync-cmd 'chr sync --build'
set -g @pocket-pane-chrsync-layout '30%,vertical'
set -g @pocket-pane-chrsync-exit-behavior 'ask'
bind -n M-S run-shell "#{@pocket-pane-path}/pocket-pane.sh toggle chrsync"
# Toggle test/echo bottom pane (40% width) bound to M-t.
set -g @pocket-pane-quicktest-cmd 'echo "lesgoooooo!"'
set -g @pocket-pane-quicktest-layout '40%,horizontal,full'
set -g @pocket-pane-quicktest-exit-behavior 'ask'
bind -n M-t run-shell "#{@pocket-pane-path}/pocket-pane.sh toggle quicktest"