I often find myself needing the current branch name, for which currently 
there's git rev-parse --abrev-ref HEAD. I would expect `git branch` to have an 
option to output the branch name instead.

This is my first patch to Git, so process-related comments (patch formatting, 
et cetera) are quite welcome.

Daniels Umanovskis (2):
  branch: introduce --current display option
  doc/git-branch: Document the --current option

 Documentation/git-branch.txt |  6 +++++-
 builtin/branch.c             | 16 ++++++++++++++++
 t/t3203-branch-output.sh     | 18 ++++++++++++++++++
 3 files changed, 39 insertions(+), 1 deletion(-)

-- 
2.19.1.272.gf84b9b09d.dirty

Reply via email to