Created
July 11, 2014 08:48
-
-
Save kteru/0ddab08210bd196fec93 to your computer and use it in GitHub Desktop.
既にセッションがある時はアタッチ、無いときは新規作成
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
function tm() { | |
if [ -n "${1}" ]; then | |
tmux -2 attach-session -t ${1} || \ | |
tmux -2 new-session -s ${1} | |
else | |
tmux -2 attach-session || \ | |
tmux -2 new-session | |
fi | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment