Stripping git on_branch? return value; contains trailing newline

This commit also contains git provider `latest' method formatting changes;
squashed by request.
Merge pull request #109 from mikegerwitz/master

Bug fix: Git provider on_branch? retains trailing newline