Skip to content

Instantly share code, notes, and snippets.

@michaelcarwile
Created March 7, 2014 20:34
Show Gist options
  • Select an option

  • Save michaelcarwile/9419482 to your computer and use it in GitHub Desktop.

Select an option

Save michaelcarwile/9419482 to your computer and use it in GitHub Desktop.
Full path display in bash prompt
Somewhere in your .bashrc put this
# Sets command line prompt PS1
if [ -f ~/.ps1 ]; then
. ~/.ps1
fi
Then the .ps1 file looks like this
$ cat .ps1
# set PS1 prompt to host:path crlf $
PS1='$PWD'
PS1="$LOGNAME@dev:$PS1"
PS1="$PS1
$ "
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment