HACKER Q&A
📣 mattrighetti

How do you efficiently keep track of the changes/features in a commit?


I often find myself working on a project for an entire day and when it's time to commit I spend a lot of time trying to remember what are the changes and what are the new features that I've introduced in the codebase.

I've once tried to make a commit every time I introduce something that should be noted and then at the end of the day squash all those new commit into one, but this felt a bit strange and it required a significant amount of work at the time of merging all the commits' messages into the squashed one.

Can somebody point me out to some best practices for this?


  👤 _false Accepted Answer ✓
Making regular commits is a good thing to do. Not sure why would you squash all the commits from a day?

It is common to squash all commits from a branch, when merging though (https://softwareengineering.stackexchange.com/questions/2631...).

Try writing good commit messages (https://chris.beams.io/posts/git-commit/).