Resolve branch name if SCM is git using git-branch command