Skip to content

Instantly share code, notes, and snippets.

@mohnish
Forked from tj/prompt.sh
Created August 7, 2012 19:19
Show Gist options
  • Save mohnish/3288571 to your computer and use it in GitHub Desktop.
Save mohnish/3288571 to your computer and use it in GitHub Desktop.
function git_branch {
git branch --no-color 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/\ \(\1\)/'
}
PS1=" λ \W\$(git_branch): "
PS2=" | "
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment