re: Easily get current branch name in git VIEW POST


While not a fancy one-liner or anything, I tend to just use git status to see "On branch ____" and just copy that as needed. Not great for scripting but easy to remember


This is what I do too. Or in Sublime using the Git plugin, activate the command palette then type "br" which jumps to "Git: Change Branch" with an asterisk next to the current branch.

code of conduct - report abuse