Skip to content

Instantly share code, notes, and snippets.

@seungjin
Created October 18, 2014 01:10
Show Gist options
  • Save seungjin/f408f9e793a829a1699b to your computer and use it in GitHub Desktop.
Save seungjin/f408f9e793a829a1699b to your computer and use it in GitHub Desktop.
tmux detach instead exit it
exit() {
if [[ -z $TMUX ]]; then
builtin exit
else
tmux detach
fi
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment