From b12d406573aef97a24be230c3a087c81dedbf1a4 Mon Sep 17 00:00:00 2001 From: garrytan Date: Thu, 29 Oct 2026 07:33:24 +0000 Subject: [PATCH] docs(pregate, ship-policy): the fragment fold's two receipt rules, and clear applies them too Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> --- docs/pregate.md | 7 +++++-- docs/ship-policy.md | 10 ++++++---- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/docs/pregate.md b/docs/pregate.md index 1e8698852..e9b059c20 100644 --- a/docs/pregate.md +++ b/docs/pregate.md @@ -447,7 +447,8 @@ receipt for H when the two trees differ only as a stamp does: stamps, each hunk in them must be the exact old → new rewrite under `stamp_patterns` (literal `{version}` templates) or the built-in forms (`(was X)`, `since: X`, `vX`), and the version file, `package.json`'s - `version`, a lockfile's root version keys and a CHANGELOG re-heading have + `version`, a lockfile's root version keys and a CHANGELOG re-heading (under + `changelog_fragments`, also the fold of the fragments the head deletes) have their own built-in rules. There is no second list and no looser rule here: the file verdicts `clear` reaches on a pair are the verdicts `gstack-tree-receipt --gated G --current H` reaches, and its gate rule holds @@ -466,7 +467,9 @@ receipt for H when the two trees differ only as a stamp does: the policy label (`origin/@:.gstack/ship-policy.json`) and every differing path with the rule that classed it (`version-file`, `version-manifest`, `manifest-version`, `lockfile-root-version`, - `changelog-heading`, `stamp_files`, `stamp_paths`, `release_outputs`). `clear` prints the same + `changelog-heading`, `changelog-fragments` for the CHANGELOG under the fold, + `changelog_fragments` for a folded fragment's deletion, `stamp_files`, + `stamp_paths`, `release_outputs`). `clear` prints the same as `PREGATE_RECEIPT_SUBSTITUTED: …`, `verify` repeats it on its ok line, and the ship receipt carries the receipt string. The receipt's own tests and failed checks apply as before (its exit status is checked only when diff --git a/docs/ship-policy.md b/docs/ship-policy.md index 3792e7e43..075aabcb3 100644 --- a/docs/ship-policy.md +++ b/docs/ship-policy.md @@ -1198,10 +1198,12 @@ writes no version in Step 12 and writes Step 13's entry as **The fold.** `gstack-restamp` (and so `land`) concatenates the fragment bodies in path order above any legacy `[Unreleased]` section, re-heads both as one `## [] - ` section at the top, and deletes the fragment -files, in one stamp. The tree receipt's `changelog-fragments` rule calls a -deleted fragment a stamp only when its body appears verbatim, in order, among -the lines added under the new heading; an edited fold, or a fragment deleted -without its text, is a change. +files, in one stamp. The tree receipt, and so `gstack-pregate clear`'s +stamp-only substitution, calls a deleted fragment a stamp (rule +`changelog_fragments`) only when the new CHANGELOG section is exactly the +deleted fragments' bodies in path order above any legacy `[Unreleased]` text +(rule `changelog-fragments`); an edited fold, or a fragment deleted without +its text, is a change. **Version Gate.** The workflow runs on every PR (no path filter), so a PR that touches no release file still has to prove its entry. Under the key, an