Skip to content

Instantly share code, notes, and snippets.

@toantran-ea
Created January 18, 2017 16:44
Show Gist options
  • Save toantran-ea/4d67afbc119f0934755aef4eac2a1acb to your computer and use it in GitHub Desktop.
Save toantran-ea/4d67afbc119f0934755aef4eac2a1acb to your computer and use it in GitHub Desktop.
tmux configuration - cross machines (macbook + linux station)
# set prefix to be Ctrl-a
set -g prefix C-a
# unbind original ctrl-b
unbind C-b
# setting the delay between prefix and command
set -s escape-time 1
# set the base index for windows to 1
set -g base-index 1
# set base index for pane to 1
setw -g pane-base-index 1
# reload the file with Prefix r
bind r source-file ~/.tmux.conf\; display "Reloaded!"
# ensure we can send C-a to other apps
bind C-a send-prefix
# split panes with | and -
bind | split-window -h
bind - split-window -v
# moving between panes with hjkl
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
# quick window selection
bind -r C-h select-window -t:-
bind -r C-l select-window -t:+
# pane resizing panes with Prefix H J K L
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
# enable mouse-on
set -g mouse on
# set the default terminal mode to 256color mode
set -g default-terminal "screen-256color"
# set the status line's colors
set -g status-style fg=white,bold,bg=black
# set color of window list
setw -g window-status-style fg=cyan,bg=black
# set color for the active window
setw -g window-status-current-style fg=white,bold,bg=red
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment