### --- Settings --- ### # general set -as terminal-features 'xterm*:extkeys' set -g base-index 1 set -g pane-base-index 1 set -g default-shell /bin/bash set -g detach-on-destroy off set -s extended-keys on set -g focus-events on set -g history-limit 1000000 set -g mouse on set -g renumber-windows on set -g set-clipboard on set -g xterm-keys on set -gq allow-passthrough on set -ga update-environment TERM set -ga update-environment TERM_PROGRAM set -sg escape-time 0 setw -g mode-keys vi setw -g aggressive-resize on # activity set -g monitor-activity on set -g visual-activity off # color set -g default-terminal "xterm-256color" set -ga terminal-overrides ',xterm-256color:Tc' set -sa terminal-features ',xterm-256color:RGB' # status set -g status-interval 1 set -g status-justify absolute-centre set -g status-left "" set -g status-left-length 10 set -g status-position top set -g status-right "" set -g status-style "bg=default" ### --- Key Bindings --- ### # clear bind 'l' "send-keys C-l; send-keys -R; clear-history" # copy-mode bind 'v' copy-mode # pane bind '%' split-window -h -c '#{pane_current_path}' bind '"' split-window -v -c '#{pane_current_path}' bind '|' split-window -h bind '-' split-window -v bind -r 'C-down' resize-pane -D 5 bind -r 'C-up' resize-pane -U 5 bind -r 'C-left' resize-pane -L 5 bind -r 'C-right' resize-pane -R 5 bind '@' choose-window 'join-pane -h -s "%%"' bind '#' choose-window 'join-pane -s "%%"' bind 'x' kill-pane bind 'a' kill-pane -a bind 'X' kill-window bind 'A' kill-window -a bind -n 'M-k' move-pane -h -t '.{up-of}' bind -n 'M-l' move-pane -t '.{right-of}' bind -n 'M-h' move-pane -t '.{left-of}' bind -n 'M-j' move-pane -h -t '.{down-of}' # prefix unbind 'C-b' set -g prefix 'C-Space' bind 'C-Space' send-prefix # reload unbind 'r' bind 'r' source-file "~/.config/tmux/tmux.conf" # session bind -r '(' switch-client -p \; refresh-client -S bind -r ')' switch-client -n \; refresh-client -S bind -nr 'M-<' switch-client -p \; refresh-client -S bind -nr 'M->' switch-client -n \; refresh-client -S bind "'" switch-client -t'{marked}' bind -r 'BSpace' switch-client -l # window bind -r '<' swap-window -d -t -1 bind -r '>' swap-window -d -t +1 bind -nr 'M-,' previous-window \; refresh-client -S bind -nr 'M-.' next-window \; refresh-client -S bind 'c' new-window -c "#{pane_current_path}" bind -nr 'M-BSpace' last-window