Why bother with "git hygiene"?

I’m a big fan of meaningful commit messages.

commit ef4d5ce5b6f13a3cc07f8941449bcaf445111cbf
Author: Jonathan Hall <flimzy@flimzy.com>
Date:   Thu Feb 11 10:35:34 2021 +0100

    bugfix

just doesn’t cut it.

I’m also a big fan of git rebase instead of git merge, fixup and ammend, and a whole host of other git tricks to keep my git history pristine and readable.

But why?

I rarely find myself doing git archeaology, so why fuss with all this?
— Maybe you. Probably someone you work with.

My response:

I rarely find myself in an automobile accident, so why bother wearing a seat belt?

When you do need it, a clean git history, like a seatbelt, is a lifesaver (although perhaps less literally).

Share this