Say that a build from a linked worktree needs the version passed in (closes #111) #114

Merged
clawbot merged 1 commits from issue-111-worktree-version-build-arg into next 2026-10-06 06:33:20 +02:00
Collaborator

Adds one sentence to prompts/REPO_POLICIES.md, right after the rule that a plain docker build . with no build arguments must succeed. A checkout whose .git is a file (a linked worktree, or a repository checked out as a submodule) is the exception: that file points to a git directory outside the build context, so the build cannot read the version and the plain build fails. Such a build is given its version with --build-arg VERSION=..., as script/docker and script/cibuild already do. The version check in the Dockerfile example is unchanged.

Both checklists repeat that rule, so they get the same sentence in the same place. In prompts/EXISTING_REPO_CHECKLIST.md it ends at --build-arg VERSION=..., because the sentence after it already names the two scripts.

Nothing else in prompts/ says a plain docker build . succeeds from such a checkout. The later rule that a plain build "of a clone" stamps the version from git describe stays as it is: a linked worktree is not a clone, and the new sentence names the submodule case.

Checked once on a scratch repository: from a linked worktree the plain build stops at the version check, and with --build-arg VERSION=... it succeeds.

Closes #111

Model: opus-5-5

Adds one sentence to `prompts/REPO_POLICIES.md`, right after the rule that a plain `docker build .` with no build arguments must succeed. A checkout whose `.git` is a file (a linked worktree, or a repository checked out as a submodule) is the exception: that file points to a git directory outside the build context, so the build cannot read the version and the plain build fails. Such a build is given its version with `--build-arg VERSION=...`, as `script/docker` and `script/cibuild` already do. The version check in the `Dockerfile` example is unchanged. Both checklists repeat that rule, so they get the same sentence in the same place. In `prompts/EXISTING_REPO_CHECKLIST.md` it ends at `--build-arg VERSION=...`, because the sentence after it already names the two scripts. Nothing else in `prompts/` says a plain `docker build .` succeeds from such a checkout. The later rule that a plain build "of a clone" stamps the version from `git describe` stays as it is: a linked worktree is not a clone, and the new sentence names the submodule case. Checked once on a scratch repository: from a linked worktree the plain build stops at the version check, and with `--build-arg VERSION=...` it succeeds. Closes https://git.eeqj.de/sneak/prompts/issues/111 Model: opus-5-5
clawbot added the needs-review label 2026-10-06 04:58:13 +02:00
clawbot self-assigned this 2026-10-06 04:58:13 +02:00
Author
Collaborator

FAIL

  1. prompts/EXISTING_REPO_CHECKLIST.md, version item: the new sentence ends "as script/docker and script/cibuild already do" and the next sentence begins "script/docker and script/cibuild pass the version they compute on the host", so the same thing is said twice in a row. This item is already worded apart from the policy, so here end the new sentence at --build-arg VERSION=... and let the following sentence carry the scripts, for example "script/docker and script/cibuild already pass the version they compute on the host; it takes precedence."
  2. TODO.md Completed Steps conflicts with next, which added the entry for #105 at the top. Rebase onto next with this change's entry above that one, both kept whole.

Judgement call: the later rule that a plain docker build . of a clone stamps the version is read as not covering a submodule checkout, as the PR body argues.

Model: opus-5-5

FAIL 1. `prompts/EXISTING_REPO_CHECKLIST.md`, version item: the new sentence ends "as `script/docker` and `script/cibuild` already do" and the next sentence begins "`script/docker` and `script/cibuild` pass the version they compute on the host", so the same thing is said twice in a row. This item is already worded apart from the policy, so here end the new sentence at `--build-arg VERSION=...` and let the following sentence carry the scripts, for example "`script/docker` and `script/cibuild` already pass the version they compute on the host; it takes precedence." 2. `TODO.md` Completed Steps conflicts with `next`, which added the entry for https://git.eeqj.de/sneak/prompts/issues/105 at the top. Rebase onto `next` with this change's entry above that one, both kept whole. Judgement call: the later rule that a plain `docker build .` of a clone stamps the version is read as not covering a submodule checkout, as the PR body argues. Model: opus-5-5
clawbot added needs-rework and removed needs-review labels 2026-10-06 05:23:56 +02:00
clawbot force-pushed issue-111-worktree-version-build-arg from 2155080be8 to 605d5a29f7 2026-10-06 05:35:24 +02:00 Compare
clawbot added needs-review and removed needs-rework labels 2026-10-06 05:35:36 +02:00
Author
Collaborator
  1. Fixed: the new sentence in prompts/EXISTING_REPO_CHECKLIST.md ends at --build-arg VERSION=..., and the next one reads "script/docker and script/cibuild already pass the version they compute on the host; it takes precedence." The policy and the new-repo checklist have no such repetition and are unchanged.
  2. Fixed: rebased onto next; this change's TODO.md entry sits above the one for #105, both whole.

Model: opus-5-5

1. Fixed: the new sentence in `prompts/EXISTING_REPO_CHECKLIST.md` ends at `--build-arg VERSION=...`, and the next one reads "`script/docker` and `script/cibuild` already pass the version they compute on the host; it takes precedence." The policy and the new-repo checklist have no such repetition and are unchanged. 2. Fixed: rebased onto `next`; this change's `TODO.md` entry sits above the one for https://git.eeqj.de/sneak/prompts/issues/105, both whole. Model: opus-5-5
clawbot added 1 commit 2026-10-06 05:55:20 +02:00
A plain `docker build .` from a checkout whose `.git` is a file (a linked worktree, or a repository checked out as a submodule) stops at the version check of the canonical `Dockerfile`: that file points to a git directory outside the build context, so `git describe` prints nothing. The policy said a plain build must succeed and did not name this case.

`prompts/REPO_POLICIES.md` and both checklists now say, right after that rule, that such a checkout is the exception and is given its version with `--build-arg VERSION=...`, as `script/docker` and `script/cibuild` already do. The check is unchanged.

Model: opus-5-5
clawbot force-pushed issue-111-worktree-version-build-arg from 605d5a29f7 to e5b7ffbfd5 2026-10-06 05:55:20 +02:00 Compare
Author
Collaborator

Rebased onto current next after #109: TODO.md keeps both Completed Steps entries whole with this one on top, and prompts/REPO_POLICIES.md and both checklists keep both changes.

Model: opus-5-5

Rebased onto current `next` after https://git.eeqj.de/sneak/prompts/pulls/109: `TODO.md` keeps both Completed Steps entries whole with this one on top, and `prompts/REPO_POLICIES.md` and both checklists keep both changes. Model: opus-5-5
Author
Collaborator

PASS: both earlier findings are fixed, and the change meets the definition of done of #111.

Model: opus-5-5

PASS: both earlier findings are fixed, and the change meets the definition of done of https://git.eeqj.de/sneak/prompts/issues/111. Model: opus-5-5
clawbot merged commit 01954b6946 into next 2026-10-06 06:33:20 +02:00
clawbot deleted branch issue-111-worktree-version-build-arg 2026-10-06 06:33:21 +02:00
Sign in to join this conversation.