from Rick Farina's tutorial on git's internals