-
-
Save jhenry/773937 to your computer and use it in GitHub Desktop.
./tmux_starter_pistol.sh projectname
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export PROJECT_NAME=$1 | |
export WORKING_DIR=~/working/active/$PROJECT_NAME | |
cd $WORKING_DIR; | |
tmux start-server | |
tmux new-session -d -s $PROJECT_NAME -n work | |
tmux new-window -t$PROJECT_NAME:1 -n server | |
tmux new-window -t$PROJECT_NAME:2 -n test | |
tmux send-keys -t$PROJECT_NAME:0 'cd $WORKING_DIR && vim .' C-m | |
tmux send-keys -t$PROJECT_NAME:1 'cd $WORKING_DIR && rails s' C-m | |
tmux send-keys -t$PROJECT_NAME:2 'cd $WORKING_DIR && bundle exec autotest -f' C-m | |
tmux select-window -t$PROJECT_NAME:0 | |
tmux attach-session -d -t$PROJECT_NAME |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment