Skip to content

Instantly share code, notes, and snippets.

@srijan
Created July 23, 2014 10:49
Show Gist options
  • Save srijan/3f8a310eaf12c9253c34 to your computer and use it in GitHub Desktop.
Save srijan/3f8a310eaf12c9253c34 to your computer and use it in GitHub Desktop.
Tmux config file
unbind C-b
set -g prefix ^A
bind a send-prefix
# Bind appropriate commands similar to screen.
unbind ^X
bind ^X lock-server
unbind x
bind x lock-server
# screen ^C c
unbind ^C
bind ^C new-window
unbind c
bind c new-window
# detach ^D d
unbind ^D
bind ^D detach
# displays *
unbind *
bind * list-clients
# next ^@ ^N sp n
unbind ^@
bind ^@ next-window
unbind ^N
bind ^N next-window
unbind " "
bind " " next-window
unbind n
bind n next-window
# title A
unbind A
bind A command-prompt "rename-window %%"
# other ^A
unbind ^A
bind ^A last-window
# prev ^H ^P p ^?
unbind ^H
bind ^H previous-window
unbind ^P
bind ^P previous-window
unbind p
bind p previous-window
unbind BSpace
bind BSpace previous-window
# windows ^W w
unbind ^W
bind ^W list-windows
unbind w
bind w list-windows
# quit \
unbind \
bind \ confirm-before "kill-server"
# kill K k
unbind K
bind K confirm-before "kill-window"
unbind k
bind k confirm-before "kill-window"
# redisplay ^L l
unbind ^L
bind ^L refresh-client
unbind l
bind l refresh-client
# More straight forward key bindings for splitting
unbind %
bind | split-window -h
bind v split-window -h
unbind '"'
bind - split-window -v
bind h split-window -v
# History
set -g history-limit 1000
# Terminal emulator window title
set -g set-titles on
set -g set-titles-string '#S:#I.#P #W'
# Status Bar
set -g status-bg black
set -g status-fg white
set -g status-interval 1
set -g status-left '#[fg=green]#H#[default]'
set -g status-right '#[fg=yellow]#(cut -d " " -f 1-4 /proc/loadavg)#[default] #[fg=cyan,bold]%Y-%m-%d %H:%M:%S#[default]'
# Highlighting the active window in status bar
setw -g window-status-current-bg red
# Clock
setw -g clock-mode-colour green
setw -g clock-mode-style 24
# " windowlist -b
unbind '"'
bind '"' choose-window
# Start window numbering at 1
set -g base-index 1
# force a reload of the config file
unbind r
bind r source-file ~/.tmux.conf
# Setting term
set -g default-terminal "screen-256color"
set -g terminal-overrides 'xterm*:smcup@:rmcup@'
bind D source-file ~/.tmux/default
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment