Skip to content

Instantly share code, notes, and snippets.

@benwtks benwtks/blog.sh
Created Feb 20, 2020

Embed
What would you like to do?
Tmux scripts
#!/bin/bash
cd ~/blog
tmux new -s Blog -d
tmux send-keys -t Blog 'git s' C-m
tmux rename-window -t Blog Zsh
tmux new-window -t Blog
tmux send-keys -t Blog 'vim' C-m
tmux rename-window -t Blog Vim
tmux new-window -t Blog
tmux send-keys -t Blog 'bundle exec jekyll serve' C-m
tmux rename-window -t Blog Server
tmux select-window -t Blog:1
tmux attach -t Blog
#!/bin/bash
cd $1
tmux new -s Development -d
tmux new-window -t Development
tmux send-keys -t Development 'vim' C-m
tmux new-window -t Development
tmux select-window -t Development:1
session=$(echo $(basename "$PWD") | sed -e "s/\b\(.\)/\u\1/g" | tr "-" " ")
tmux rename-session -t Development "$session"
tmux attach -t "$session"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.