Commit messages with superfluous empty lines on the top generate
empty summaries. Trim the commit message so the summary contains
something meaningful (as far as the commit message permits).
* Avoid creating an array for the sole purpose of counting elements
Probably speeds up counting commits for git versions < 1.8.0,
although I dubt it would make a visible difference
* Fix commit count with git version < 1.8.0
With format='' the output does not end with a newline (checked)
* Adds functions to handle checking out branches and moving files
Adds support for checking out a new branch
Fix for branch pull requests
* Adds methods to get files changes between two commits
This fixes regression introduced in ebd9fb2253,
that GetSubModules was always returning empty submodule info because
c.submoduleCache != nil check was always true since parseCommitData was setting
commit.submoduleCache = newObjectCache() so it was always not-nil.
Now we initialize submoduleCache in first GetSubModules call, next call will
return cached entries.