Write down two commit rules that were only ever conventions
Both were being followed by habit and neither was written anywhere, so each new contributor (human or agent) had to rediscover them: - Never amend. An existing commit is history someone may already have read; corrections belong in the next commit, not in a rewrite of the last one. - Every commit is a release candidate. Landing a half-applied refactor or a fix whose test is still to come leaves the tree in a state where the pre-commit gate no longer means what it claims. Large changes get split into independently sound steps, not into a break followed by a repair.
This commit is contained in:
1 parent
e73c87d49b
commit
6c4f33f3ee
1 file changed
+8
@@ -248,6 +248,14 @@ When diagnosing a hang, prefer reading full `cargo test` output over piping thro
|
||||
warnings; CI will fail the same checks.
|
||||
- Do not force-push shared history unless the user asks.
|
||||
- Do not commit secrets, large binaries, or lockfiles that this repo intentionally ignores.
|
||||
- **Never amend a commit** unless the user explicitly asks for it in the current conversation. A
|
||||
commit that is already written is history someone else may have read; correct it by adding the
|
||||
next commit, not by rewriting the last one.
|
||||
- **Every commit is a release candidate.** Do not land partial work, a half-applied refactor, or a
|
||||
fix whose test is still to come. Each commit must build, pass the pre-commit gate above, and leave
|
||||
no capability worse off than the commit before it. If a change is too large to land in one sound
|
||||
step, split it into steps that are each independently sound - not into a broken step followed by a
|
||||
repair.
|
||||
|
||||
## The loop (unit of work)
|
||||
|
||||
|
||||
Reference in new issue
Block a user