Skip to content

Instantly share code, notes, and snippets.

@dimfeld
Last active August 29, 2015 14:21
Show Gist options
  • Save dimfeld/097924c695049cfedb4b to your computer and use it in GitHub Desktop.
Save dimfeld/097924c695049cfedb4b to your computer and use it in GitHub Desktop.
set -g base-index 1
set -s escape-time 0
# Window Switching
bind-key -n C-NPage next
bind-key -n C-PPage prev
bind-key -n C-M-NPage swap-window -t +1
bind-key -n C-M-PPage swap-window -t -1
bind-key n next
bind-key N prev
bind-key m swap-window -t +1
bind-key M swap-window -t -1
bind-key r source ~/.tmux.conf
bind-key C-b last-window
set -g history-limit 50000
set -g set-titles on
set -g set-titles-string "#I - #W"
set -g bell-action any
# Status bar empty except for window list
set -g status-left ""
set -g status-right ""
set -g status-right-length 0
# Uncomment to remove status bar completely...
# set -g status off
# v and y like vi in copy mode
bind-key -t vi-copy 'v' begin-selection
bind-key -t vi-copy 'y' copy-selection
bind-key V copy-mode
bind-key P choose-buffer
bind-key p paste-buffer
bind-key -n S-PPage copy-mode -u
bind-key -r -t vi-copy C-p page-up
bind-key -r -t vi-copy C-s page-down
bind-key -r -t vi-copy S-PPage page-up
bind-key -n C-p copy-mode -u
bind-key s split-window
bind-key v split-window -h
bind-key k confirm-before kill-pane
set -g display-time 2000
set-window-option -g window-status-current-fg yellow
set-window-option -g window-status-current-bg black
# Window selection
unbind-key 1 ; bind-key 1 select-window -t 1
unbind-key 2 ; bind-key 2 select-window -t 2
unbind-key 3 ; bind-key 3 select-window -t 3
unbind-key 4 ; bind-key 4 select-window -t 4
unbind-key 5 ; bind-key 5 select-window -t 5
unbind-key 6 ; bind-key 6 select-window -t 6
unbind-key 7 ; bind-key 7 select-window -t 7
unbind-key 8 ; bind-key 8 select-window -t 8
unbind-key 9 ; bind-key 9 select-window -t 9
unbind-key 0 ; bind-key 0 select-window -t 10
unbind-key M-1 ; bind-key -n M-1 select-window -t 1
unbind-key M-2 ; bind-key -n M-2 select-window -t 2
unbind-key M-3 ; bind-key -n M-3 select-window -t 3
unbind-key M-4 ; bind-key -n M-4 select-window -t 4
unbind-key M-5 ; bind-key -n M-5 select-window -t 5
unbind-key M-6 ; bind-key -n M-6 select-window -t 6
unbind-key M-7 ; bind-key -n M-7 select-window -t 7
unbind-key M-8 ; bind-key -n M-8 select-window -t 8
unbind-key M-9 ; bind-key -n M-9 select-window -t 9
unbind-key M-0 ; bind-key -n M-0 select-window -t 10
set -g mode-mouse on
# Need both of these for it to apply to the first window?
setw -g xterm-keys on
setw xterm-keys on
# move x clipboard into tmux paste buffer
bind C-p run "tmux set-buffer \"$(xclip -o)\"; tmux paste-buffer"
# # move tmux copy buffer into x clipboard
bind C-y run "tmux show-buffer | xclip -i"
setw -g aggressive-resize on
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment