Add getTagOrBranchName method to do job in plugin

Always in the spirit of
http://stackoverflow.com/questions/18659425/get-git-current-branch-tag-name
adding a getTagOrBranchName() method makes it super easy for the
grunt-gitinfo plugin to return the tag name if present, otherwise the
branch name.

I'll add documentation if this PR is accepted.

Cheers