Skip to content

Instantly share code, notes, and snippets.

@jakebathman
Last active December 14, 2017 17:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jakebathman/4671e70c68307da3fc313a19908dd6be to your computer and use it in GitHub Desktop.
Save jakebathman/4671e70c68307da3fc313a19908dd6be to your computer and use it in GitHub Desktop.
Customizing tmux
# Many of these customizations are from
# http://www.hamvocke.com/blog/a-guide-to-customizing-your-tmux-conf/
# remap prefix from 'C-b' to 'C-a'
unbind C-b
set-option -g prefix C-a
bind-key C-a send-prefix
# split panes using | and -
bind | split-window -h
bind - split-window -v
unbind '"'
unbind %
# switch panes using Alt-arrow without prefix
bind -n M-Left select-pane -L
bind -n M-Right select-pane -R
bind -n M-Up select-pane -U
bind -n M-Down select-pane -D
# Enable mouse control (clickable windows, panes, resizable panes)
# tmux <2.1
#set -g mouse-select-window on
#set -g mouse-select-pane on
#set -g mouse-resize-pane on
# tmux 2.1+
# Enable mouse mode (tmux 2.1 and above)
set -g mouse on
# Change color of bottom bar
set -g default-terminal "xterm-256color"
set -g status-bg colour160 # red
set -g status-fg colour255 # bright white
set -g window-status-current-bg colour255 # bright white
set -g window-status-current-fg colour160 # red
# Change color of pane border lines
set -g pane-border-fg colour0
set -g pane-active-border-fg colour160
# Change color of tmux clock pane
set-window-option -g clock-mode-colour cyan
# Enable Tmux Resurrect plugin
#
# This should already installed via:
# git clone https://github.com/tmux-plugins/tmux-resurrect ~/tmux-plugins
run-shell ~/tmux-plugins/resurrect.tmux
# Enable tmux sidebar plugin
run-shell ~/tmux-plugins/tmux-sidebar/sidebar.tmux
set -g @sidebar-tree-command 'tree -C'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment