Skip to content

Instantly share code, notes, and snippets.

@breiter
Created June 24, 2020 11:37
Show Gist options
  • Select an option

  • Save breiter/749684af88d32af349820f37cf2dc8e0 to your computer and use it in GitHub Desktop.

Select an option

Save breiter/749684af88d32af349820f37cf2dc8e0 to your computer and use it in GitHub Desktop.
Restore terminal title when ssh exits
# Add to ~/.bashrc
#
# force reset of the current directory name in terminal title
# to reset it after SSH sessions end.
PROMPT_COMMAND='echo -ne "\033]0;$(basename ${PWD})\007"'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment