Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save daniepetrov/e312e0f63547675326b53433dafeaa01 to your computer and use it in GitHub Desktop.
Save daniepetrov/e312e0f63547675326b53433dafeaa01 to your computer and use it in GitHub Desktop.
Show full path on OS X terminal / iTerm before the $ prompt
1. Edit ~/.bash_profile and add the following line to show full path before the $ prompt.
For example, as user@hostname:path/to/directory$
# show path before the $ prompt
export PS1='\u@\H:\w$ '
2. Save file and restart terminal or run source command
$ source ~/.bash_profile
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment