tmuxen

tmux environment made easy
git clone git://git.unixkoans.com/tmuxen.git
Log | Files | Refs

commit 8cd5e75585e9110b6970e6af8a025fb331455274
parent 7d21b54e9cb242ba1fda81f19233be5812e15a08
Author: Xiaodong Xu <[email protected]>
Date:   Sat Jul  7 16:49:20 +0800

Add more comments for tmux.conf

Diffstat:
_tmux.conf | 70+++++++++++++++++++++++++++++++++++++++++-----------------------------
1 file changed, 41 insertions(+), 29 deletions(-)
diff --git a/_tmux.conf b/_tmux.conf @@ -1,48 +1,60 @@ # # author : Xu Xiaodong <[email protected]> -# modified : 2012 Jul 01 +# modified : 2012 Jul 07 # -#-- base --# +#-- base settings --# set -g default-terminal "screen-256color" set -g display-time 3000 +set -g escape-time 0 set -g history-limit 65535 set -g base-index 1 set -g pane-base-index 1 -set -s escape-time 0 #-- bindkeys --# +# prefix key (Ctrl+a) set -g prefix ^a unbind ^b bind a send-prefix +# split window unbind '"' -bind - splitw -v +bind - splitw -v # vertical split (prefix -) unbind % -bind | splitw -h - -bind k selectp -U -bind j selectp -D -bind h selectp -L -bind l selectp -R - -bind -r ^k resizep -U 10 -bind -r ^j resizep -D 10 -bind -r ^h resizep -L 10 -bind -r ^l resizep -R 10 - -bind ^u swapp -U -bind ^d swapp -D - -bind ^e last -bind q killp - -bind ! splitw htop -bind m command-prompt "splitw 'exec man %%'" -bind @ command-prompt "splitw 'exec perldoc -t -f %%'" -bind * command-prompt "splitw 'exec perldoc -t -v %%'" -bind % command-prompt "splitw 'exec perldoc -t %%'" -bind / command-prompt "splitw 'exec ri %%'" +bind | splitw -h # horizontal split (prefix |) + +# select pane +bind k selectp -U # above (prefix k) +bind j selectp -D # below (prefix j) +bind h selectp -L # left (prefix h) +bind l selectp -R # right (prefix l) + +# resize pane +bind -r ^k resizep -U 10 # upward (prefix Ctrl+k) +bind -r ^j resizep -D 10 # downward (prefix Ctrl+j) +bind -r ^h resizep -L 10 # to the left (prefix Ctrl+h) +bind -r ^l resizep -R 10 # to the right (prefix Ctrl+l) + +# swap pane +bind ^u swapp -U # swap with the previous pane (prefix Ctrl+u) +bind ^d swapp -D # swap with the next pane (prefix Ctrl+d) + +# misc +bind e lastp # select the last pane (prefix e) +bind ^e last # select the last window (prefix Ctrl+e) +bind q killp # kill pane (prefix q) +bind ^q killw # kill window (prefix Ctrl+q) + +# app +bind ! splitw htop # htop (prefix !) +bind m command-prompt "splitw 'exec man %%'" # man (prefix m) +bind @ command-prompt "splitw 'exec perldoc -t -f %%'" # perl func (prefix @) +bind * command-prompt "splitw 'exec perldoc -t -v %%'" # perl var (prefix *) +bind % command-prompt "splitw 'exec perldoc -t %%'" # perl doc (prefix %) +bind / command-prompt "splitw 'exec ri %%'" # ruby doc (prefix /) + +# reload config +bind r source ~/.tmux.conf \; display "Configuration reloaded!" #-- statusbar --# set -g status-utf8 on @@ -82,7 +94,7 @@ set -g status-right-length 80 setw -g window-status-current-fg colour223 setw -g window-status-current-bg colour237 setw -g window-status-current-attr bold -setw -g window-status-current-format '#I:#W#F' +setw -g window-status-current-format "#I:#W#F" #setw -g window-status-alert-attr bold #setw -g window-status-alert-fg colour255