Created
June 7, 2011 18:50
-
-
Save ddollar/1012870 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ~/.tmux.conf | |
# | |
# See the following files: | |
# | |
# /opt/local/share/doc/tmux/t-williams.conf | |
# /opt/local/share/doc/tmux/screen-keys.conf | |
# /opt/local/share/doc/tmux/vim-keys.conf | |
# | |
# URLs to read: | |
# | |
# http://blog.yjl.im/2009/11/migrating-to-tmux-from-gnuscreen.html | |
# http://blog.hawkhost.com/2010/06/28/tmux-the-terminal-multiplexer/ | |
# http://blog.hawkhost.com/2010/07/02/tmux-%E2%80%93-the-terminal-multiplexer-part-2/ | |
# http://www.dayid.org/os/notes/tm.html | |
# | |
# Other sample tmux.conf files | |
# | |
# http://www.mindfuzz.net/?p=178 | |
# | |
# ----------------------------------------------------------------------------- | |
## GLOBAL SETTINGS | |
# Set prefix key to ` | |
unbind C-b | |
set -g prefix ` | |
# send the prefix to client inside window | |
bind ` send-prefix | |
# scrollback buffer n lines | |
set -g history-limit 30000 | |
# listen for activity on all windows | |
set -g bell-action any | |
# start window indexing at zero (default) | |
set -g base-index 0 | |
# instructs tmux to expect UTF-8 sequences | |
setw -g utf8 on | |
# tell tmux to use 256 colour terminal | |
set -g default-terminal "screen-256color" | |
# xterm-style function key sequences | |
setw -g xterm-keys on | |
# control automatic window renaming | |
setw -g automatic-rename on | |
# enable wm window titles | |
set -g set-titles on | |
## KEY BINDINGS | |
# reload settings | |
bind R source-file ~/.tmux.conf | |
# detach client | |
bind d detach | |
# choose a client to detach | |
bind D choose-client | |
# choose window/session | |
bind "'" choose-window | |
bind '"' choose-session | |
# display visible indicator of each pane | |
bind w display-panes | |
# swap panes | |
bind -r J swap-pane -D | |
bind -r K swap-pane -U | |
# kill current pane/window | |
bind q confirm-before kill-pane | |
bind Q confirm-before kill-window | |
# copying and pasting | |
bind [ copy-mode | |
bind ] paste-buffer -s \015 | |
bind \ save-buffer ~/.tmux-buffer \; run-shell "cat ~/.tmux-buffer | pbcopy" | |
# vi-style controls for copy mode | |
setw -g mode-keys vi | |
# enable mouse selection in copy mode | |
setw -g mode-mouse on | |
# new window | |
bind c new-window | |
# alternatively, use better mnemonics for horizontal/vertical splits | |
bind - split-window -v | |
bind _ split-window -v | |
bind | split-window -h | |
# resize panes like vim | |
bind -r < resize-pane -L 3 | |
bind -r > resize-pane -R 3 | |
bind -r + resize-pane -U 1 | |
bind -r = resize-pane -D 1 | |
## STATUS BAR | |
# toggle statusbar | |
bind s set status | |
# use vi-style key bindings in the status line | |
set -g status-keys vi | |
# amount of time for which status line messages and other indicators | |
# are displayed. time is in milliseconds. | |
set -g display-time 2000 | |
# use mouse to select tmux window | |
set -g mouse-select-pane on | |
setw -g mode-mouse on | |
# dont wait forever for esc sequences | |
set -s escape-time 10 | |
# set status bar | |
set -g status-utf8 on | |
set -g status-fg colour39 | |
set -g status-bg colour17 | |
set -g status-left ' #S' | |
set -g status-right '#[bg=black]#T#[bg=default] ' | |
set -g status-right-length 60 | |
set -g status-left-length 60 | |
## inactive windows | |
setw -g window-status-bg colour0 | |
setw -g window-status-fg colour25 | |
setw -g window-status-format ' #[fg=colour28]#I#[fg=colour237]:#[default]#W ' | |
## highlight active window | |
setw -g window-status-current-bg colour0 | |
setw -g window-status-current-fg colour255 | |
setw -g window-status-current-format ' #[fg=colour220]#I#[fg=colour245]:#[default]#W ' | |
# ----------------------------------------------------------------------------- | |
# vim: fen fdl=0 fdm=marker |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment