Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
55 lines (43 sloc) 1.79 KB
# 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
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
bind ^h select-pane -L
bind ^j select-pane -D
bind ^k select-pane -U
bind ^l select-pane -R
# resize panes like vim
# feel free to change the "1" to however many lines you want to resize by, only
# one at a time can be slow
bind < resize-pane -L 1
bind > resize-pane -R 1
bind - resize-pane -D 1
bind + resize-pane -U 1
# bind : to command-prompt like vim
# this is the default in tmux already
bind : command-prompt
# vi-style controls for copy mode
set-window-option -g mode-keys vi
set-window-option -g xterm-keys on
set -g default-terminal "screen-256color"
# Set the prefix to ^A.
unbind C-b
set -g prefix ^A
bind a send-prefix
# Styling
set-option -g status-style "bg=colour240"
set-option -g status-left "#[fg=colour250] [sess:#S] "
set-option -g status-right ""
set-window-option -g window-status-format "#[fg=colour240, bg=colour235]#[fg=colour255] #I#[fg=colour250]: #W #[fg=colour235, bg=colour240]"
set-window-option -g window-status-current-format "#[fg=colour240, bg=colour250]#[fg=colour235, bg=colour250] #I: #W #[fg=colour250, bg=colour240]"
# Make copy-paste work on OS X with https://github.com/ChrisJohnsen/tmux-MacOSX-pasteboard
# For a portable version requiring a separate shell script, see https://github.com/jimeh/dotfiles/commit/3838db8#diff-a923c6fe127f95f1048bc447300c5764R21
#set-option -g default-command "reattach-to-user-namespace -l bash"
set -g update-environment "DISPLAY WINDOWID SSH_ASKPASS SSH_AGENT_PID SSH_CONNECTION"