Another reason I don't like squashing commits within pull/merge request is losing detail within the commit messages.
As someone who usually writes detailed commit messages that explain why the change is being made, any gotchas or alternative approaches that were tried, etc, I want that information to be retained.
Previously, when working on a team and doing merge/pull requests, when merging a feature or release branch, either the tool or reviewer would delete all the messages from the squashed commits.
The time I spent writing the messages was wasted, and the information was lost.
I'd rather keep the original commits intact but, if you need to squash commits, please don't remove the previous messages as they could be useful in the future.
People can see the changes by viewing the commits, but the information within the commit messages are valuable, too.
- Oliver
Was this interesting?
About me
I'm an Acquia-certified Drupal Triple Expert with 17 years of experience, an open-source software maintainer and Drupal core contributor, public speaker, live streamer, and host of the Beyond Blocks podcast.