Skip to content

Instantly share code, notes, and snippets.

@jpemberthy
Created April 8, 2015 16:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jpemberthy/d36fa602d48633d1cf17 to your computer and use it in GitHub Desktop.
Save jpemberthy/d36fa602d48633d1cf17 to your computer and use it in GitHub Desktop.
# source-file ...
# Use C-a for the prefix
set -g prefix C-a
unbind C-b
# Basic settings
set -sg escape-time 1
set -g base-index 1
set -g pane-base-index 1
bind C-a send-prefix
bind r source-file ~/.tmux.conf \; display "Reloaded!"
# More sane split-window bindings
bind | split-window -h
bind - split-window -v
# Act like vim
set -g mode-keys vi
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
bind -r C-h select-window -t :-
bind -r C-l select-window -t :+
bind -r H resize-pane -L 5
bind -r J resize-pane -D 5
bind -r K resize-pane -U 5
bind -r L resize-pane -R 5
# Mouse
setw -g mode-mouse on
set -g mouse-select-pane on
set -g mouse-resize-pane on
set -g mouse-select-window on
# Make it all look good
set -g status-utf8 on
set-option -g status-bg colour227
set-option -g status-fg colour16
set -g status-left '#[bold]⣿ ❐ #S ⡇#[default]'
set -g status-right '#[bold]#(whoami) ● #H#[default] '
set-window-option -g automatic-rename on
set-window-option -g window-status-fg colour227
set-window-option -g window-status-bg colour238
set-window-option -g window-status-format ' #I #W '
set-window-option -g window-status-attr dim
set-window-option -g window-status-current-bg colour52
set-window-option -g window-status-current-fg colour227
set-window-option -g window-status-current-format ' #I #W '
set-window-option -g window-status-current-attr dim
set-option -g set-titles on
set-option -g set-titles-string '#S:#W'
## pane border and colors
set-option -g pane-active-border-fg yellow
set-option -g pane-border-fg white
set -g status-interval 60
set -g status-justify left
setw -g monitor-activity on
set -g visual-activity on
unbind Up
bind Up new-window -d -n tmp \; swap-pane -s tmp.1 \; select-window -t tmp
unbind Down
bind Down last-window \; swap-pane -s tmp.1 \; kill-window -t tmp
bind P pipe-pane -o "cat >>/tmp/tmux-#S-#W.log" \; display "Toggled logging to /tmp/tmux-#S-#W.log"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment