Skip to content

Instantly share code, notes, and snippets.

@lleger
Created June 4, 2015 20:05
Show Gist options
  • Save lleger/e7def3de1b831803d2c9 to your computer and use it in GitHub Desktop.
Save lleger/e7def3de1b831803d2c9 to your computer and use it in GitHub Desktop.
# better copy and past
bind-key -t vi-copy v begin-selection
bind-key -t vi-copy y copy-pipe "reattach-to-user-namespace pbcopy"
unbind -t vi-copy Enter
bind-key -t vi-copy Enter copy-pipe "reattach-to-user-namespace pbcopy"
# improve colors
set -g default-terminal 'screen-256color'
# act like vim
setw -g mode-keys vi
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
bind-key -r C-h select-window -t :-
bind-key -r C-l select-window -t :+
# act like GNU screen
unbind C-b
set -g prefix C-a
# start window numbers at 1 to match keyboard order with tmux window order
set -g base-index 1
# renumber windows sequentially after closing any of them
set -g renumber-windows on
# soften status bar color from harsh green to light gray
set -g status-bg '#666666'
set -g status-fg '#aaaaaa'
# remove administrative debris (session name, hostname, time) in status bar
set -g status-left '#S'
set -g status-right '#h'
# put status bar up top and center
set -g status-justify centre
set -g status-position top
# increase scrollback lines
set -g history-limit 10000
# switch to last pane
bind-key C-a last-pane
# reload config without killing server
bind R source-file ~/.tmux.conf \; display-message "Configuration reloaded."
# shortcut to redraw screen
bind-key C-r attach -d
# shortcuts to split windows
bind-key V split-window -v
bind-key H split-window -h
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment