Some dogmatic opinions about the practice of version control:
The centralized (single trunk repository) model of version control is simplest. Prefer it. If you must use a decentralized system like Git, don't create forks needlessly.
Never rewrite history. Undo commits with new commits.
If a system provides "lightweight" (Git-style) branches, treat them like "real" branches; i.e. assume that everything committed to them will be forever part of your repository's history. A branch is an abstraction barrier, not a way to save face.
Don't create unneeded or "topic" branches. Each additional branch in a repository makes the project harder to understand.
Write commit messages carefully: use standard spelling and punctuation, and make sure they clearly express the changes made and, if the commit is significant, the reasons for making them. Make things clear. It may be a decade or more before someone needs to understand your changes.
Be careful not to stuff unrelated changes into a merge commit. If major changes are needed before you can merge cleanly, record them in ordinary commits.
Avoid using clever tricks and unfamiliar VCS features. Complicated version-control practices create complicated software. (You need look no further than Git for evidence of this.)
© 2025 Wolfgang Corcoran-Mathe. Released under the terms of the Creative Commons Attribution 4.0 International license.