Skip to content
Browse files

add tmux-panes script

  • Loading branch information...
1 parent c2b28bf commit f49293f5fd5e9e8196fed79df4998b0f43442923 Mingxiang.Zhang committed May 21, 2012
Showing with 16 additions and 9 deletions.
  1. +9 −9 .tmux.conf
  2. +4 −0 README
  3. +3 −0 tmux-panes
View
18 .tmux.conf
@@ -21,7 +21,7 @@ setw -g pane-base-index 1
bind r source-file ~/.tmux.conf \; display "Reloaded!"
# splitting panes
-bind | split-window -h
+bind \ split-window -h
bind - split-window -v
# moving between panes
@@ -30,7 +30,7 @@ bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
-# Quick pane selection
+# cycle through windows
bind -r C-h select-window -t :-
bind -r C-l select-window -t :+
@@ -40,11 +40,11 @@ bind -r J resize-pane -D 5
bind -r K resize-pane -U 5
bind -r L resize-pane -R 5
-# mouse support - set to on if you want to use the mouse
-setw -g mode-mouse off
-set -g mouse-select-pane off
-set -g mouse-resize-pane off
-set -g mouse-select-window off
+# mouse support - set to off if you don't want to use the mouse
+setw -g mode-mouse on
+set -g mouse-select-pane on
+set -g mouse-resize-pane on
+set -g mouse-select-window on
# Set the default terminal mode to 256color mode
set -g default-terminal "screen-256color"
@@ -99,8 +99,8 @@ setw -g mode-keys vi
# Open panes in the same directory using the tmux-panes script
unbind v
unbind n
-bind v send-keys " ~/tmux-panes -h" C-m
-bind n send-keys " ~/tmux-panes -v" C-m
+bind v send-keys " ~/dotfiles/tmux-panes -h" C-m
+bind n send-keys " ~/dotfiles/Tmux-panes -v" C-m
# Maximize and restore a pane
unbind Up
View
4 README
@@ -16,3 +16,7 @@ $ git submodule add https://github.com/gmarik/vundle.git bundle/vundle
4, install vim plugin
start vim and execute the next in command line mode
:BundleInstall
+
+5, For tmux
+$ chmod +x tmux-panes
+$ ln -sf ~/dotfiles/.tmux.conf ~
View
3 tmux-panes
@@ -0,0 +1,3 @@
+TMUX_CURRENT_DIR=`pwd`
+tmux split-window $1
+tmux send-keys "cd $TMUX_CURRENT_DIR;clear" C-m

0 comments on commit f49293f

Please sign in to comment.
Something went wrong with that request. Please try again.