Skip to content

Instantly share code, notes, and snippets.

@diginc
Last active January 3, 2016 22:09
Show Gist options
  • Save diginc/8526252 to your computer and use it in GitHub Desktop.
Save diginc/8526252 to your computer and use it in GitHub Desktop.
~/bin $ cat tm-default
#!/bin/bash
TMUXNAME=${1:-"default"}
if tmux ls | grep "^$TMUXNAME:"; then
tmux attach -d -t $TMUXNAME
else
tmux new -s $TMUXNAME
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment