Commit 8aa8acb0 authored by Derek Willian Stavis's avatar Derek Willian Stavis Committed by GitHub

lib/git: fix branch name in detached head (#366)

parent e4bd035f
function git_branch_name -d "Get current branch name"
git_is_repo; and begin
command git symbolic-ref --short HEAD
command git symbolic-ref --short HEAD ^/dev/null;
or command git show-ref --head -s --abbrev | head -n1 ^/dev/null
end
end
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment