Skip to content

Instantly share code, notes, and snippets.

@JamesChevalier
Created September 6, 2012 13:39

Revisions

  1. JamesChevalier created this gist Sep 6, 2012.
    12 changes: 12 additions & 0 deletions gistfile1.sh
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,12 @@
    # unstaged (*) and staged (+) changes will be shown next to the branch name
    GIT_PS1_SHOWDIRTYSTATE="."
    # if there are untracked files (%) will be shown next to the branch name
    GIT_PS1_SHOWUNTRACKEDFILES="."
    # if something is stashed ($) will be shown next to the branch name
    GIT_PS1_SHOWSTASHSTATE="."
    # you are behind (<), you are ahead (>), or you have diverged (<>)
    GIT_PS1_SHOWUPSTREAM="auto"

    # White brackets, yellow path, blue branch name, and cyan dollar sign
    # [~/working/path (branch-name-with-indicator)]$
    PS1='[\[\033[0;33m\]\w\[\033[0;34m\]`__git_ps1`\[\033[0m\]]\[\033[0;36m\]\$ \[\033[0m\]'