Skip to content

Instantly share code, notes, and snippets.

@Happyholic1203
Created August 22, 2016 06:36
Show Gist options
  • Save Happyholic1203/f01ecd3d48550bb292746206de19f79e to your computer and use it in GitHub Desktop.
Save Happyholic1203/f01ecd3d48550bb292746206de19f79e to your computer and use it in GitHub Desktop.
# Source: https://gist.github.com/v-yarotsky/2157908
# Usage:
# - Prefix is set to Ctrl-o (make sure you remapped Caps Lock to Ctrl)
# - All prefixed with Ctrl-o
# - Last used window: /
# - Last used pane: ;
# - Vertical split: v
# - Horizontal split: s
### KEYS ###
# using C-o as prefix
unbind C-b
set-option -g prefix C-o
bind C-o send-prefix
unbind /
bind / last-window
unbind %
bind s split-window -v
bind S choose-tree
unbind '"'
bind v split-window -h
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
set-window-option -g mode-keys vi
bind-key -t vi-copy 'v' begin-selection
bind-key -t vi-copy 'y' copy-selection
set -g default-terminal "screen-256color"
set-window-option -g aggressive-resize on
set-option -g default-command "which reattach-to-user-namespace >/dev/null 2>&1 && reattach-to-user-namespace -l $SHELL || /bin/bash"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment