Overview
With version control system (VCS) introduced, we need to hanle commits properly, which is the way we push our changes to the VCS. In this documentation, the focus here are:
- How to write good commit logs
- How to be atomic commits
Commit logs
Basically reference [1] has well described:
- Why good commit messages matter
- The seven rules of a great Git commit message
I recommand we could follow these rules in general. Meanwhile, I think following topics need be considered properly as well.
Start subject title with module name
This is probably one exception for the rule Capitalize the subject line. This is normally applied to project that consists of multiple relatively independent sub-components. In that case, start commit message subject line with the component name would make it easier to know where this change is applied. Also filtering based on commit log would be an efficient way to group changes for one component out of all. Linux Kernel and Git itself use this way.
Be atomic commits
Reference [2] has well described this topic.