Re:Why large companies and fast-moving startups are banning ...
by wandernotlost on Sunday December 31, 2023 @06:04PM
(#38828293)
If I've already pushed my branch, typically I have a draft PR open and tests are being run against it, and I'm not going to force push, because that's obnoxious and I've probably prohibited it in the repo.
If it's a local commit and I catch it in ten seconds, I will sometimes throw up in my mouth a little bit as I amend the commit.
I view source control as one of the best places for an immutable log of events, and prefer immutable logs for many things in general, for a variety of reasons. So yes, I fix forward.
You know, the word "history" might be abused by git as much as the word "friend" is by facebook.
BTW, I never really got an answer to this one: what do you do when you notice a typo ten seconds after you committed? A new commit that says "typo fix", or squash the commit on to the previous commit?