Skip to content

Instantly share code, notes, and snippets.

@yanhsiah
Last active March 19, 2019 09:48
Show Gist options
  • Save yanhsiah/bd1c59d06f9daf149480182f85d117dd to your computer and use it in GitHub Desktop.
Save yanhsiah/bd1c59d06f9daf149480182f85d117dd to your computer and use it in GitHub Desktop.
.tmux.conf
unbind C-b
set -g prefix ^A
bind a send-prefix
# set colors
set-window-option -g window-status-current-fg blue
set-window-option -g window-status-current-bg yellow
set-window-option -g window-status-current-attr default
# switch to next window
unbind C-Right
bind -n C-Right next-window
# switch to previous window
unbind C-Left
bind -n C-Left previous-window
# split windows like vim
# vim's definition of a horizontal/vertical split is reversed from tmux's
bind s split-window -v
bind v split-window -h
# move around panes with hjkl, as one would in vim after pressing ctrl-w
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
# vi-style controls for copy mode
setw -g mode-keys vi
unbind [
bind Escape copy-mode
unbind p
bind p paste-buffer
# bind-key -t vi-copy 'v' begin-selection
# bind-key -t vi-copy 'y' copy-selection
unbind ,
bind A command-prompt "rename-window '%%'"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment