Skip to content

Instantly share code, notes, and snippets.

@jwise77
Last active May 1, 2019 22:22
Show Gist options
  • Save jwise77/07a9c26a058cccfc0745efc0e2d1c6c1 to your computer and use it in GitHub Desktop.
Save jwise77/07a9c26a058cccfc0745efc0e2d1c6c1 to your computer and use it in GitHub Desktop.
# improve colors
set -g default-terminal "screen-256color"
# soften status bar color from harsh green to light gray
set -g status-bg '#666666'
set -g status-fg '#aaaaaa'
unbind C-b
set -g prefix C-a
bind-key C-a last-window
bind-key Space next-window
bind-key BSpace previous-window
bind-key k kill-window
bind-key Escape copy-mode
bind-key | split-window -h
bind-key - split-window -v
bind a send-prefix
bind r source-file ~/.tmux.conf \; display "Reloaded!"
#========================================================================
# Mouse settings
#========================================================================
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-keys -X halfpage-up
bind -T copy-mode-vi C-WheelDownPane send-keys -X halfpage-down
bind -T copy-mode-emacs C-WheelUpPane send-keys -X halfpage-up
bind -T copy-mode-emacs C-WheelDownPane send-keys -X halfpage-down
# To copy, left click and drag to highlight text in yellow,
# once you release left click yellow text will disappear and will automatically be available in clibboard
# # Use vim keybindings in copy mode
setw -g mode-keys vi
# Update default binding of `Enter` to also use copy-pipe
unbind -T copy-mode-vi Enter
bind-key -T copy-mode-vi Enter send-keys -X copy-pipe-and-cancel "xclip -selection c"
bind-key -T copy-mode-vi MouseDragEnd1Pane send-keys -X copy-pipe-and-cancel "xclip -in -selection clipboard"
#========================================================================
######################
### DESIGN CHANGES ###
######################
# loud or quiet?
set-option -g visual-activity off
set-option -g visual-bell off
set-option -g visual-silence off
set-window-option -g monitor-activity off
set-option -g bell-action none
# modes
setw -g clock-mode-colour colour5
setw -g mode-style fg=colour1,bg=colour18,bold
# panes
set -g pane-border-style fg=colour19,bg=colour0
set -g pane-active-border-style fg=colour9,bg=colour0
# statusbar
set -g status-position bottom
set -g status-justify left
set -g status-style bg=colour18,fg=colour137,dim
set -g status-left ''
set -g status-right '#[fg=colour100,bg=colour19,bold] %d-%h #[fg=colour233,bg=colour8,bold] %H:%M '
set -g status-right-length 50
set -g status-left-length 20
setw -g window-status-current-style fg=colour1,bg=colour19,bold
setw -g window-status-current-format ' #I#[fg=colour249]:#[fg=colour255]#W#[fg=colour249]#F '
setw -g window-status-current-style fg=colour9,bg=colour18,none
setw -g window-status-format ' #I#[fg=colour237]:#[fg=colour250]#W#[fg=colour244]#F '
setw -g window-status-bell-style fg=colour255,bg=colour1,bold
# messages
set -g message-style fg=colour3,bg=black,bold
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment