Skip to content

Instantly share code, notes, and snippets.

@campbell

campbell/.tmux.conf

Last active May 19, 2016
Embed
What would you like to do?
# remap prefix to Control + q
set -g prefix C-q
unbind C-b
bind C-a send-prefix
# force a reload of the config file
unbind r
bind r source-file ~/.tmux.conf
# quick pane cycling
unbind ^A
bind ^A select-pane -t :.+
# http://superuser.com/questions/209437/how-do-i-scroll-in-tmux
set -g mode-mouse on
# enable copy-paste http://goo.gl/DN82E
# enable RubyMotion http://goo.gl/WDlCy
#set -g default-command "reattach-to-user-namespace -l zsh"
# Enable mouse control (clickable windows, panes, resizable panes)
set -g mouse-select-window on
set -g mouse-select-pane on
set -g mouse-resize-pane on
# Clear the history and buffer
bind -n C-k clear-history
# https://robots.thoughtbot.com/tmux-copy-paste-on-os-x-a-better-future
# Use vim keybindings in copy mode
setw -g mode-keys vi
# Setup 'v' to begin selection as in Vim
bind-key -t vi-copy v begin-selection
bind-key -t vi-copy y copy-pipe "reattach-to-user-namespace pbcopy"
# Update default binding of `Enter` to also use copy-pipe
unbind -t vi-copy Enter
bind-key -t vi-copy Enter copy-pipe "reattach-to-user-namespace pbcopy"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment