Skip to content

Instantly share code, notes, and snippets.

@nefftd
Created March 4, 2015 16:04
Show Gist options
  • Save nefftd/66f6b93d53cc00bb53ba to your computer and use it in GitHub Desktop.
Save nefftd/66f6b93d53cc00bb53ba to your computer and use it in GitHub Desktop.
d)
OUT="$(tmux detach 2>&1)"
if [[ "$OUT" =~ ^(failed to connect to server) ]]; then
echo "tm: tmux server not active" 1>&2;
ERRCODE = 1
elif [[ $? != 0 ]]; then
[[ -z "$OUT" ]] && echo $OUT 1>&2;
ERRCODE = 1
fi
;;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment