Created
December 1, 2021 13:53
-
-
Save hoegaarden/dea2ec4e5fca72b469b94304e559b7c6 to your computer and use it in GitHub Desktop.
tmux
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Plugins | |
set -g @plugin 'tmux-plugins/tpm' | |
set -g @plugin 'tmux-plugins/tmux-sensible' | |
set -g @plugin 'tmux-plugins/tmux-yank' | |
set -g @plugin 'tmux-plugins/tmux-prefix-highlight' | |
set -g @plugin 'tmux-plugins/tmux-copycat' | |
set -g @plugin 'tmux-plugins/tmux-pain-control' | |
set -g @prefix_highlight_show_copy_mode 'on' | |
set -g @prefix_highlight_copy_mode_attr 'fg=black,bg=yellow' | |
set -g @prefix_highlight_fg 'colour231' | |
set -g @prefix_highlight_bg 'colour09' | |
# visuals {{{ | |
set-option -g visual-activity on | |
set-option -g visual-bell on | |
set-option -g visual-silence off | |
set-window-option -g monitor-activity on | |
set-option -g bell-action none | |
# status line | |
set -g status-justify left | |
set -g status-bg default | |
set -g status-fg colour12 | |
set -g status-interval 2 | |
# modes | |
setw -g clock-mode-colour colour135 | |
setw -g mode-style bg=yellow | |
# panes | |
set -g pane-border-style bg=colour235,fg=colour238 | |
set -g pane-active-border-style bg=colour236,fg=colour51 | |
# statusbar | |
set -g status-position bottom | |
set -g status-style dim,bg=colour234,fg=colour137 | |
set -g status-left '#{prefix_highlight}' | |
set -g status-right '#[fg=blue] %a, %Y-%m-%d #[fg=colour5]%H:%M:%S #[default]|#[fg=green,bright] #h#[fg=white](#[fg=blue]#S#[fg=white])' | |
# window status | |
set -g window-status-separator '' | |
setw -g window-status-current-style fg=colour81,bg=colour242,bold | |
setw -g window-status-current-format ' #I#[fg=colour250]:#[fg=colour255]#W#[fg=colour50]#F ' | |
setw -g window-status-style fg=colour138,bg=colour236,none | |
setw -g window-status-format ' #I#[fg=colour242]:#[fg=colour250]#W#[fg=colour244]#F ' | |
setw -g window-status-bell-style bold,fg=colour255,bg=colour1 | |
# messages | |
set -g message-style fg=colour232,bg=colour166,bold | |
set -g message-command-style fg=blue,bg=black | |
# set escape key timeout to 0 | |
set -s escape-time 0 | |
# visuals }}} | |
run '~/.tmux/plugins/tpm/tpm' | |
# set-option -s default-terminal "screen-256color" | |
set-option -s default-terminal "xterm-256color" | |
# https://neovim.io/doc/user/term.html#tui-cursor-shape | |
# set -ga terminal-overrides '*:Ss=\E[%p1%d q:Se=\E[ q' | |
# Use vim keybindings in copy mode | |
setw -g mode-keys vi | |
bind-key -T copy-mode-vi v send -X begin-selection | |
set-option -g prefix C-space | |
bind-key C-space last-window | |
# split panes using | and - | |
bind \\ split-window -h -c "#{pane_current_path}" | |
bind | split-window -h -f -c "#{pane_current_path}" | |
bind - split-window -v -c "#{pane_current_path}" | |
bind _ split-window -v -f -c "#{pane_current_path}" | |
unbind '"' | |
unbind % | |
# Start numbering at 1 | |
set -g base-index 1 | |
# mouse {{{ | |
set -g mouse on | |
bind -n WheelUpPane if-shell -F -t = "#{mouse_any_flag}" "send-keys -M" "if -Ft= '#{pane_in_mode}' 'send-keys -M' 'select-pane -t=; copy-mode -e; send-keys -M'" | |
bind -n WheelDownPane select-pane -t= \; send-keys -M | |
bind -n C-WheelUpPane select-pane -t= \; copy-mode -e \; send-keys -M | |
bind -T copy-mode-vi C-WheelUpPane send -X halfpage-up | |
bind -T copy-mode-vi C-WheelDownPane send -X halfpage-down | |
bind -T copy-mode C-WheelUpPane send -X halfpage-up | |
bind -T copy-mode C-WheelDownPane send -X halfpage-down | |
unbind -T copy-mode-vi MouseDragEnd1Pane | |
# mouse }}} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment