Handle encoding header of Git commits when possible.

Handle encoding header of Git commits when possible.