use git symbolic-ref to detect current branch

* faster than git branch especially with many branches