Skip to content

Instantly share code, notes, and snippets.

@kch
Created January 5, 2010 13:47
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kch/269378 to your computer and use it in GitHub Desktop.
Save kch/269378 to your computer and use it in GitHub Desktop.
git get name of current branch
# Previous versions of this gist brought to you by major OCD.
# I now leave you with my pick.
git branch | ack -o '(?<=^\* ).*'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment