Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
executable file 58 lines (45 sloc) 1.59 KB
unbind C-b
unbind C-a
set -g prefix C-a
setw -g mode-keys vi
# use | and - to split the windows
bind-key | split-window -h
bind-key - split-window -v
# Act like vim for selecting panes
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
# keybindings to make resizing easier
bind -r C-h resize-pane -L
bind -r C-j resize-pane -D
bind -r C-k resize-pane -U
bind -r C-l resize-pane -R
# make the first window number start at 1
set -g base-index 1
# to have nice colors
set -g default-terminal "xterm-256color"
set-option -g default-shell /bin/zsh
set-option -g history-limit 5000
# see https://github.com/ChrisJohnsen/tmux-MacOSX-pasteboard
#just works on the mac, gotta see how to feature detect this
#set-option -g default-command "reattach-to-user-namespace -l $(basename $SHELL)"
set-option -g default-command "reattach-to-user-namespace -l zsh"
# reload conf file
bind C-r source-file ~/.tmux.conf \; display-message "reloaded"
# fixes esc delay
set -s escape-time 0
# copy and paste with a vim-like interface
unbind [
bind Escape copy-mode
unbind p
bind p paste-buffer
bind-key -T copy-mode-vi 'v' send -X begin-selection
bind-key -T copy-mode-vi 'y' send -X copy-pipe-and-cancel "reattach-to-user-namespace pbcopy"
# allows pane resize to w/e size wanted
setw -g aggressive-resize on
#new-window -d -k -n tmux-zoom -t 99 'clear && echo -n "ZOOM" "MARK" & read'
#unbind +
#bind + find-window "ZOOM[ ]MARK" \; swap-pane -s tmux-zoom.0 \; last-window \; swap-pane -s tmux-zoom.0 \; select-window -t tmux-zoom
#unbind -
#bind - find-window "ZOOM[ ]MARK" \; swap-pane -s tmux-zoom.0