Use --abbrev-commit to make sure that short hashes are unique.

As documented: http://git-scm.com/book/ch6-1.html#Short-SHA.