docs(adr): align ADR-0033, AGENTS.md and delivery.md on release tags
ADR-0033 said the git-v1.3.8 one-off could be cut "with --ref", which without --plugin tags every plugin at that commit, and said an agent may run --apply only when asked, contradicting AGENTS.md. It also did not cover a reverted version, which the script now reports as RELEASED. - ADR-0033: a version is released once, at its first landing (revert case); the one-off is the exact --ref <sha> --plugin git --apply command; agents run --apply locally after a bump merges and the maintainer pushes; hand or Gitea create_tag cuts are a maintainer path. - AGENTS.md: agents cut release tags only with the script. - delivery.md: Conventions bullets reduced to pointers, per the delivery-repo-doc format (section 6, no restating). Refs: #223 Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_014uGZTNugst7K9Bd2FTR4Mi
This commit is contained in:
1 parent
f677698887
commit
b3cdcc9bbb
3 files changed
+26
-17
No files matched your search
@@ -38,7 +38,12 @@ Two facts limit where enforcement can live:
|
||||
landed on `main`, never a feature-branch commit. An `apm.yml` edit that leaves `version:` alone
|
||||
does not start a new run.
|
||||
- **Immutability.** Tags are never moved, overwritten or silently re-cut. A tag that is lightweight
|
||||
or that peels to the wrong commit is reported as an error for a human to resolve.
|
||||
or that peels to no landing of its version is reported as an error for a human to resolve.
|
||||
- **A version is released once, at its first landing.** When a version comes back (a reverted
|
||||
bump, or an `apm.yml` deleted and re-added), the later run is not tagged again: its tag already
|
||||
exists on the earlier run, so the script reports that run `RELEASED` and it blocks nothing. An
|
||||
untagged version that recurs within the wanted runs is tagged at its first landing there, and
|
||||
the later runs report `RELEASED`.
|
||||
- **Mechanism.** `scripts/tag-plugin-releases.sh` computes the targets from `origin/main`'s
|
||||
history and cuts the tags after merge. Without arguments it is a dry run: it prints a
|
||||
`plugin version commit status` table and exits 1 if any tag is missing. `--apply` creates the
|
||||
@@ -46,25 +51,31 @@ Two facts limit where enforcement can live:
|
||||
exact `git push origin <tag>…` line, naming each tag explicitly and never using `--tags`. The
|
||||
script never fetches and never pushes. No hook gates any of this.
|
||||
- **Which versions are wanted.** If a plugin already has a `<plugin>-v*` tag reachable from
|
||||
`main`, the script wants every version run from the newest such tag onward. If it has none, the
|
||||
script wants only the current run. That second rule is the backfill: older history is not
|
||||
`main`, the script wants every version run from the newest such tag onward, including a reverted
|
||||
version's run, which then reports `RELEASED` as above. If it has none, the script wants only the
|
||||
current run. That second rule is the backfill: older history is not
|
||||
tagged retroactively.
|
||||
- **One deliberate exception to the backfill: git's previous version, `git-v1.3.8`, is also
|
||||
tagged**, on `32fbe39fb8923854ca8e743a0d2cad81720c736c`, where 1.3.8 first landed on `main`. This
|
||||
gives a consumer pinned to an older git tag something real to check `apm outdated` against. It is
|
||||
a one-off, cut by hand or with `--ref`. After it, the "from the newest tag onward" rule covers
|
||||
git like every other plugin.
|
||||
a one-off, cut with exactly
|
||||
`scripts/tag-plugin-releases.sh --ref 32fbe39fb8923854ca8e743a0d2cad81720c736c --plugin git --apply`,
|
||||
which tags git alone; without `--plugin git` that `--ref` would tag every plugin's version at
|
||||
that commit. After it, the "from the newest tag onward" rule covers git like every other plugin.
|
||||
- **Pushing a release tag is a maintainer-only action. It is not a Propose-tier push under
|
||||
ADR-0032.** ADR-0032's Propose tier ("branch, commit, push, open a PR, comment") covers pushes
|
||||
that propose a change for review: a human still approves the change before it merges. A tag push
|
||||
has no review step behind it. It publishes a release that consumers pin, and because tags are
|
||||
immutable it cannot be quietly taken back. An agent may run the dry run, and may run `--apply`
|
||||
only when a maintainer asks it to. The push itself is always the maintainer's.
|
||||
locally once a version bump has merged. It then shows the maintainer the push command the
|
||||
script printed and waits; the push itself is always the maintainer's.
|
||||
- **Agents cut release tags only with the script.** Cutting one by hand or with Gitea's
|
||||
`create_tag` (consequence 4) is a maintainer path.
|
||||
- **Wiring elsewhere:**
|
||||
- Root `apm.yml`'s `marketplace.build.tagPattern` is `{name}-v{version}`.
|
||||
- `docs/agents/delivery.md` lists the script's dry run under Conventions as a post-merge check.
|
||||
It does not go under Post-merge checks, because that section accepts only forge status names
|
||||
and the repo has no CI.
|
||||
- `docs/agents/delivery.md` points at `AGENTS.md` and this ADR under Conventions. The dry run
|
||||
does not go under Post-merge checks, because that section accepts only forge status names and
|
||||
the repo has no CI.
|
||||
- `AGENTS.md` carries the agent-facing rule and cites this ADR.
|
||||
|
||||
## Considered options
|
||||
@@ -126,9 +137,9 @@ rewrites it. **It is untested.**
|
||||
}
|
||||
```
|
||||
|
||||
**4. Gitea's `create_tag` is an equivalent way to cut a tag**, provided `git cat-file -t <tag>`
|
||||
reports `tag` after fetching. That confirms it is annotated; the script reports a lightweight tag
|
||||
as an error.
|
||||
**4. For a maintainer, Gitea's `create_tag` is an equivalent way to cut a tag**, provided
|
||||
`git cat-file -t <tag>` reports `tag` after fetching. That confirms it is annotated; the script
|
||||
reports a lightweight tag as an error.
|
||||
|
||||
**5. Enforcement is by convention for now.** Nothing fails when a maintainer forgets to tag. A
|
||||
`post-merge:` assertion that the verify stage checks on version-bump PRs is the natural next step
|
||||
|
||||
@@ -32,10 +32,8 @@
|
||||
- Repo conventions and session rules: `AGENTS.md`; decisions: `docs/adr/`.
|
||||
- No forge CI: every check is a local pre-commit or pre-push hook, listed with its reason in
|
||||
`docs/spec/gates.md`; test commands in `README.md`.
|
||||
- An `.apm/` edit is live only once on the remote's `main` (ADR-0019).
|
||||
- A merged `version:` bump in `plugins/<name>/apm.yml` needs its release tag: after
|
||||
`git fetch origin --tags`, `scripts/tag-plugin-releases.sh` (dry run) exits 1 when one is
|
||||
missing. Tag form and who pushes: ADR-0033.
|
||||
- When an `.apm/` edit goes live: `AGENTS.md`, session rules; ADR-0019.
|
||||
- Release tags after a `version:` bump merges: `AGENTS.md`; ADR-0033.
|
||||
|
||||
## Post-merge checks
|
||||
|
||||
|
||||
Reference in new issue
Block a user