Something went wrong. Try again.
Something went wrong. Try again.
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197# vim: set filetype=tmux foldmethod=marker :
# {{{ block: terminal
set -g default-terminal "tmux-256color"
# OSC 8, RGB, Extended Keysset -ga terminal-features ",*:hyperlinks,*:RGB,xterm*:extkeys"
set -s extended-keys onset -g allow-passthrough on
# block: terminal }}}
# remap prefixset -g prefix C-a
# enable mouse supportset -g mouse on
# start windows and panes at 1, not 0set -g base-index 1set -gw pane-base-index 1
# sync windows number on create/destroyset -g renumber-windows on
# vi mode keys for navigationset -gw mode-keys vi
# toggle synchronize-panesbind C-x set -w synchronize-panes
# copy-mode begin-selection with vbind -T copy-mode-vi v send-keys -X begin-selection
# copy-mode prompt jumpbind -T copy-mode-vi ] send-keys -X next-promptbind -T copy-mode-vi [ send-keys -X previous-prompt
# create new windowbind c new-window -c "#{pane_current_path}"
# toggle status linebind -Troot C-F12 set statusbind -Tsuspended C-F12 set status
# navigate across tmux-vimis_vim="ps -o state= -o comm= -t '#{pane_tty}' \ | grep -iqE '^[^TXZ ]+ +(\\S+\\/)?g?(view|n?vim?x?)(diff)?$'"
bind -Troot C-w if-shell "$is_vim" "send-keys C-w" "switch-client -Tnav; refresh-client -S"
bind -Tnav C-w send-keys 'C-w'
# {{{ keybinds: select-panebind -Tnav h select-pane -Lbind h select-pane -Lbind -Tnav C-h select-pane -Lbind C-h select-pane -Lbind -Tnav j select-pane -Dbind j select-pane -Dbind -Tnav C-j select-pane -Dbind C-j select-pane -Dbind -Tnav k select-pane -Ubind k select-pane -Ubind -Tnav C-k select-pane -Ubind C-k select-pane -Ubind -Tnav l select-pane -Rbind l select-pane -Rbind -Tnav C-l select-pane -Rbind C-l select-pane -R# keybinds: select-pane }}}
# {{{ keybinds: split-windowbind -Tnav "\\" split-window -h -c "#{pane_current_path}" # verticalbind "\\" split-window -h -c "#{pane_current_path}" # verticalbind -Tnav "|" split-window -fh -c "#{pane_current_path}" # full verticalbind "|" split-window -fh -c "#{pane_current_path}" # full verticalbind -Tnav "-" split-window -v -c "#{pane_current_path}" # horizontalbind "-" split-window -v -c "#{pane_current_path}" # horizontalbind -Tnav "_" split-window -fv -c "#{pane_current_path}" # full horizontalbind "_" split-window -fv -c "#{pane_current_path}" # full horizontal# keybinds: split-window }}}
# {{{ keybinds: resize-panebind -r -Tnav M-h resize-pane -L 10bind -r M-h resize-pane -L 10bind -r -Tnav M-j resize-pane -D 5bind -r M-j resize-pane -D 5bind -r -Tnav M-k resize-pane -U 5bind -r M-k resize-pane -U 5bind -r -Tnav M-l resize-pane -R 10bind -r M-l resize-pane -R 10# keybinds: resize-pane }}}
# {{{ keybinds: swap-windowbind -r "<" swap-window -d -t -1bind -r ">" swap-window -d -t +1# keybinds: swap-window }}}
# {{{ keybinds: mousebind -Troot MouseDown1Status if -F '#{==:#{mouse_status_range},window}' { select-window} { if -F '#{==:#{mouse_status_range},switch_session}' { if 'test "$(tmux list-session | wc -l)" -eq 1' { new-session -Ads 1 } run-shell "tmux-ctrl session next" }}# keybinds: mouse }}}
set -g @plugin 'tmux-plugins/tpm'set -g @plugin 'tmux-plugins/tmux-sensible'set -g @plugin 'tmux-plugins/tmux-cowboy'
# {{{ plugin: tmux-yankset -g @yank_action 'copy-pipe'
set -g @plugin 'tmux-plugins/tmux-yank'# plugin: tmux-yank }}}
# {{{ plugin: tmux-ctrlset -g @ctrl_pane_extract_key 'Space'set -g @ctrl_pane_move_key 'M'set -g @ctrl_session_prev_key 'P'set -g @ctrl_session_next_key 'N'
set -g @plugin 'MunifTanjim/tmux-ctrl'# plugin: tmux-ctrl }}}
# {{{ block: appearance
set -gw clock-mode-colour "blue"set -gw pane-active-border-style "fg=magenta"set -gw pane-border-style "fg=brightblack"set -gw window-status-activity-style "fg=blue"set -gw window-status-bell-style "fg=yellow"set -gw window-status-current-format " #F#I:#W "set -gw window-status-current-style "fg=green,reverse"set -gw window-status-format " #F#I:#W "set -gw window-status-last-style "fg=green"set -gw window-status-separator ""set -gw window-status-style ""
set -g display-panes-active-colour "magenta"set -g display-panes-colour "brightblack"set -g message-command-style ""set -g message-style ""set -g status-left "#[range=user|switch_session] #S #[norange]"set -g status-left-style "fg=blue bold reverse"set -g status-right "%Y-%m-%d %H:%M #{tmux_mode_indicator}"set -g status-style ""
# {{{ plugin: tmux-mode-indicatorset -g @mode_indicator_prefix_mode_style "fg=blue,reverse"set -g @mode_indicator_copy_mode_style "fg=yellow,reverse"set -g @mode_indicator_sync_mode_style "fg=brightred,reverse"set -g @mode_indicator_empty_mode_style "fg=cyan,reverse"
set -g @plugin 'MunifTanjim/tmux-mode-indicator'# plugin: tmux-mode-indicator }}}
# block: appearance }}}
# {{{ plugin: tmux-suspendset -g @suspend_suspended_options " \ status-left-style::bg=black\\,fg=brightblack bold, \ status-right-style::fg=brightblack, \ window-status-current-style:gw:fg=brightblack\\,reverse, \ window-status-last-style:gw:fg=brightblack, \ window-status-style:gw:fg=brightblack, \ @mode_indicator_custom_prompt:: ---- , \ @mode_indicator_custom_mode_style::fg=brightblack\\,reverse, \"
set -g @plugin 'MunifTanjim/tmux-suspend'# plugin: tmux-suspend }}}
# {{{ ssh# if-shell 'test -n "$SSH_CLIENT" -o -n "$SSH_TTY"' {# ssh specific config goes here# }# ssh }}}
# {{{ tpmset-environment -g TMUX_PLUGIN_MANAGER_PATH "${HOME}/.tmux/plugins"# setup automagicallyif-shell 'test ! -d ~/.tmux/plugins/tpm' "run-shell '\ git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm && \ ~/.tmux/plugins/tpm/bin/install_plugins'"# initializerun-shell -b '~/.tmux/plugins/tpm/tpm'# tpm }}}