set -g default-terminal "tmux-256color" set -as terminal-overrides ',xterm*:Tc:sitm=\E[3m' set -g base-index 1 set -g buffer-limit 20 set -g display-time 1500 set -g history-limit 20000 set -g remain-on-exit off set -g renumber-windows on set -g repeat-time 300 set -g visual-activity off set -sg escape-time 0 set-option -g focus-events on setw -g allow-rename off setw -g automatic-rename off setw -g clock-mode-colour colour11 setw -g monitor-activity on setw -g mouse on setw -g pane-base-index 1 bind < swap-pane -U bind > swap-pane -D bind C-g setw synchronize-panes bind C-m if -F '#{s/off//:mouse}' 'set -g mouse off; display-message "mouse: off"' 'set -g mouse on; display-message "mouse: on"' bind C-s if -F '#{s/off//:status}' 'set status off' 'set status on' bind K confirm kill-session bind Q command-prompt -I "htop" -p "Quick window command:" "new-window '%%'" bind R source-file ~/.tmux.conf \; display-message "config: updated" bind S command-prompt -p "New Session:" "new-session -A -s '%%'" # NOTE: don't remap &/1 ... because they are used to switch windows in IRSSI. bind -n M-H resize-pane -L 2 bind -n M-J resize-pane -D 2 bind -n M-K resize-pane -U 2 bind -n M-L resize-pane -R 2 bind-key -n M-! split-window -f -l 10 -c "#{pane_current_path}" bind-key -n M-: command-prompt bind-key -n M-< swap-pane -U bind-key -n M-= choose-buffer bind-key -n M-> swap-pane -D bind-key -n M-A select-layout even-horizontal bind-key -n M-D choose-client bind-key -n M-Down swap-window -t +1 bind-key -n M-Enter new-window bind-key -n M-J choose-window 'join-pane -s "%%"' bind-key -n M-L switch-client -l bind-key -n M-Left previous-window bind-key -n M-Right next-window bind-key -n M-Up swap-window -t -1 bind-key -n M-a select-layout even-vertical bind-key -n M-j choose-window 'join-pane -h -s "%%"' bind-key -n M-l last-window bind-key -n M-m command-prompt -p "Search man pages for:" "new-window 'exec man %%'" bind-key -n M-o selectp -t :.+ bind-key -n M-p run "tmux split-window -p 10 'tmux send-keys -t #{pane_id} \"$(locate ~/ | fzf -m | paste -sd\\ -)\"'" bind-key -n M-s split-window -v bind-key -n M-t break-pane bind-key -n M-v split-window -h bind-key -n M-w choose-window bind-key -n M-x confirm-before -p "kill-pane #P? (y/n)" kill-pane bind-key -n M-y copy-mode bind-key -n M-z resize-pane -Z set -g status off # NOTE: set the following to "on" for normal behavior (i.e., window numbers only displayed when # windows > 1) set-hook -g after-new-window 'if "[ #{session_windows} -gt 1 ]" "set status off"' set-hook -g pane-exited 'if "[ #{session_windows} -lt 2 ]" "set status off"' bind Y copy-mode setw -g mode-keys vi bind-key -T copy-mode-vi v send -X begin-selection bind-key -T copy-mode-vi 'C-v' send -X rectangle-toggle set -g set-clipboard off bind-key -T copy-mode-vi y send -X copy-pipe-and-cancel "xclip -i -selection clipboard" set -g pane-active-border-style fg=colour3 set -g pane-border-style fg=colour8 set -g status-interval 5 set -g status-justify left set -g status-left "" set -g status-position top set -g status-right "#[fg=colour8] #{session_attached}a#(exec tmux ls| wc -l)s#{session_windows}w #[fg=colour4] ♯#S " if '! [ -z "$SSH_TTY" ]' 'set -g status-right "#[fg=colour8] #(whoami)@#h #[fg=colour4] ♯#S "' set -g status-style fg=colour8 set -g window-status-current-format "#[fg=colour7]#{?window_zoomed_flag,#[bg=colour1],#[bg=colour5]} #I " set -g window-status-format "#[fg=colour8]#{?pane_synchronized,#[bg=colour3],} #I " set -g window-status-separator "#[fg=colour8]" set -g window-status-activity-style bg=colour4