# ADR 0001: How consumers follow dkstack versions - Status: Accepted - Date: 2026-10-26 - Deciders: Daniel Kindl (owner) - Author: Atlas - Issue: [#3](https://github.com/daniel-kindl/dkstack/issues/3) ## Context Consumers read dkstack in two ways: 1. An agent fetches `AGENTS.md` from a raw GitHub URL and follows the relative links in it. 2. A person installs the skills with `npx skills add daniel-kindl/dkstack`. Today every absolute URL points to `main`. These files have them: `README.md`, `sample-AGENTS.md` and the bootstrap skill. The version in `package.json` then protects no consumer. Each merge to `main` reaches every consumer at once, and a consumer cannot go back. Facts that limit the options: - A raw URL can name a branch, a tag or a commit: `https://raw.githubusercontent.com/daniel-kindl/dkstack//AGENTS.md`. - Relative links in `AGENTS.md` resolve against the URL of the file. A consumer that pins the entry URL also pins every linked file. Only the absolute URLs need a ref. - raw.githubusercontent.com sends `cache-control: max-age=300`. A change can take up to 5 minutes to reach a consumer. - The team rule is: never force-push. To move a tag, you must force-push the tag ref. - The ruleset `protect-main` allows squash merges only. Every merge to `main` is one commit. - The skills CLI accepts a GitHub tree URL with a ref: `https://github.com///tree/`. On 2026-10-26, `npx skills add` with `--list` found all 8 skills at the head commit SHA of the #2 branch. A ref that contains `/` fails: the CLI reads only the part before the `/`. Release refs must not contain `/`. The goal "update once, all repos follow" conflicts with the goal "a breaking change must not reach all repos at once". The options below trade one against the other. ## Options ### Option A: consumers follow `main` URL form in every file: ```text https://raw.githubusercontent.com/daniel-kindl/dkstack/main/AGENTS.md npx skills add daniel-kindl/dkstack ``` Update: nothing to do. Each merge reaches the consumer in 5 minutes or less. Rollback: the owner reverts the change on `main` with a new PR. A consumer cannot roll back alone. As an emergency step, a consumer can replace `main` with a commit SHA in its own `AGENTS.md`. Trade-offs: - Good: no work in consumers. No release step. - Bad: no pinning. A merge is a release, so a version number has no effect. - Bad: a breaking change reaches every consumer at the same time. - Bad: a bad merge reaches every consumer before review of its effects. ### Option B: consumers pin a release tag URL form in every file: ```text https://raw.githubusercontent.com/daniel-kindl/dkstack/v1.0.0/AGENTS.md npx skills add https://github.com/daniel-kindl/dkstack/tree/v1.0.0 ``` Update: in each consumer, change `v1.0.0` to the new tag in one line. Reinstall the skills. Rollback: in the consumer, change the tag back to the previous one. Trade-offs: - Good: each consumer is stable and can roll back alone. - Good: tags never move, so no force-push is necessary. - Bad: each update is a change in each consumer. With N consumers, one release is N changes. - Bad: consumers drift to old versions. This works against "update once, all repos follow". ### Option C: a moving major ref (`v1`) for compatible changes Compatible releases (MINOR and PATCH) move `v1` forward. A breaking release starts `v2`. Each release also gets a fixed `vX.Y.Z` tag. URL form in every file: ```text https://raw.githubusercontent.com/daniel-kindl/dkstack/v1/AGENTS.md npx skills add https://github.com/daniel-kindl/dkstack/tree/v1 ``` Two ways to make `v1`: - C1, a moving tag. To move a tag, you must force-push it. This breaks the team rule. - C2, a release branch. The owner releases with a fast-forward push from `main` to `v1`: `git push origin :refs/heads/v1`. A fast-forward push is not a force-push. A ruleset on `v1` blocks force-push and deletion. Update: compatible releases need nothing in the consumer. For a new major version, change `v1` to `v2` in one line in each consumer, after you read the breaking changes in `CHANGELOG.md`. Rollback: - The owner reverts the change on `main`, releases a PATCH, and moves `v1` forward again. - As an emergency step, a consumer pins the last good `vX.Y.Z` tag. It goes back to `v1` after the fix. - `v1` itself never moves back, because that needs a force-push. Trade-offs: - Good: compatible changes reach all consumers with one release, as with option A. - Good: breaking changes reach a consumer only when it chooses, as with option B. - Good: a merge to `main` is not a release. The owner decides when a change goes out. - Bad: one more step per release, and one more ruleset to keep. - Bad: semver must be correct. A breaking change released as MINOR reaches every consumer. ## Recommendation Option C2: a `v1` release branch, with a fixed `vX.Y.Z` tag on each release. It is the only option that keeps "update once" for compatible changes and still protects consumers from breaking changes. It also separates two concerns that option A joins: merging a change and releasing it. C1 is not acceptable, because it needs a force-push. If the owner prefers the smallest design, option B is the safe second choice. It has no release branch, but each update is a change in each consumer. ## Decision Daniel Kindl accepted option C on 2026-10-26 at 14:07 (Prague), as C2. Consumers follow a `v1` release branch. Daniel moves `v1` forward with a fast-forward push only. Each release also gets a fixed `vX.Y.Z` tag. Option C1, a moving tag, is rejected because it needs a force-push. ### Amendment 2026-10-28 Daniel decided that a bot can push to `v1` or create a release tag only with his explicit OK for that release. The OK names the exact version. It never covers a production deploy or a project's release workflow, for example tangopad `release.yml`. Only Daniel starts these. This amendment replaces the team rule "no bot pushes to `v1` or creates a release tag" in Consequences. ### Amendment 2026-11-11 Daniel decided on 2026-11-11 at 07:49 (Prague) that `v1.3.0` removes workflow pages, skills and scripts. His words are "Ship as v1.3.0 and move v1 so every repo switches at once". See #127. This is an exception for one release only. The rule "A breaking release starts `v2`" applies to every later release. ### Amendment 2026-11-11, one-click release Daniel asked on 2026-11-11 at 18:08 (Prague) for a release workflow that does the full release. His words are "I want the similiar automation release workflow for dkstack - I run the job and the job does everyting and merges main to v1 brach". At 18:10 he chose option B: the job opens a release pull request and merges it when `validate` passes. See #135. The `Release` workflow now does the release steps of option C2. Only Daniel starts it. A read-only `plan` job works out the version and shows it in the run summary. The job that writes runs in the `release` environment, with Daniel as the required reviewer. Daniel's OK for the release is two actions: he starts `Release`, and he approves the `release` environment after he reads the planned version. This OK names the exact version, as the amendment of 2026-10-28 requires. The workflow pushes the tag and fast-forwards `v1`. It never force-pushes, and `v1` still moves forward only. This amendment replaces "Only Daniel does this, by hand" in Consequences. The rule "A breaking release starts `v2`" stays: the workflow stops on a breaking change. See [Release dkstack](../../versioning/index.md#release-dkstack). On 2026-11-11 at 19:06 (Prague), Daniel decided: "Set up a GitHub App for dkstack releases". The job that writes uses a token from this app, for dkstack only, with Contents, Pull requests and Workflows (write). The app is in no ruleset bypass list, so `protect-main` still requires `validate`. With `GITHUB_TOKEN` only, the release pull request did not get a `validate` check that `protect-main` counts (runs 43070086329 and 43073954019). ### Amendment 2026-11-21, no agent releases Daniel decided on 2026-11-20 at 09:34 (Prague), as D2 in #154: "D2: only the Release run I start; no agent tags, moves v1 or starts a release". This amendment replaces the amendment of 2026-10-28. No agent pushes to `v1` or creates a release tag, even with an OK. Only the `Release` run that Daniel starts does these steps. See [workflow/safety.md](../../workflow/safety.md). ### Amendment 2026-11-21, tag pins This corrects the Context. The Context says: "A consumer that pins the entry URL also pins every linked file." That is true only for relative links. The skills and the triage routes link other dkstack files with absolute URLs on `v1`. A consumer that pins a tag reads each dkstack raw URL on that tag in place of `v1`. [AGENTS.md](../../AGENTS.md#version) says this. See ATL-1 in #154. On 2026-11-21 Daniel told the agents to decide the open items of #154. His words are "you decide, fix and merge". The agent chose option A of D6: an ADR gets dated amendments. See [Amendments](../../architecture/adrs.md#amendments). ### Amendment 2026-11-21, 1.6.0 on v1 Daniel decided on 2026-11-21 that the next release is `1.6.0` on the `v1` branch. He decided it in a Claude Code chat session. His words are "I will release is as v1 1.6.0. Fix all other findings." See #288. The release has three breaking changes. It removes the agent roles page in `workflow/` (#191). It renames the anchor `coding/quality-gates.md#exceptions` to `#suppressions` (#285). It adds a hard limit: no agent releases (#205). Under [breaking changes in dkstack](../../versioning/index.md#breaking-changes-in-dkstack), each of these is MAJOR. This is an exception for one release only. For `1.6.0` only, it replaces this text in the first amendment of 2026-11-11: > This is an exception for one release only. The rule "A breaking release starts `v2`" applies to > every later release. The rule applies again to every release after `1.6.0`. The CHANGELOG entry has a "Consumer action:" line for each removed or renamed link. ## Consequences The follow-up work is issue #5 (Forge) and issue #12 (Scribe). - All files use one URL form: `README.md`, `sample-AGENTS.md` and the bootstrap skill. - The validate workflow can check that no file uses a different ref. - `versioning/index.md` gets the release and rollback steps. - Team rule: no bot pushes to `v1` or creates a release tag. Only Daniel does this, by hand. A push to `v1` releases to every consumer at once. - A ruleset protects `v1` from force-push and deletion. This is a documented publish step. Nobody does it before Daniel publishes. - Residual risk: all bots use the `daniel-kindl` GitHub account. GitHub cannot tell Daniel from a bot, so no ruleset can stop a bot from a fast-forward push to `v1`. Only the team rule stops it. - The publish steps in #13 or #14 repeat this rule, so it reaches `CONTRIBUTING.md` or `versioning/index.md`. - Test the skills install command with the real release ref before release. - No tag, `v1` branch or GitHub release is created now. Daniel creates them when he publishes.