Skip to content

build: run lathe generator from the go.mod tool directive - #6

Merged
samzong merged 2 commits into
mainfrom
fix/lathe-tool-directive
Oct 4, 2026
Merged

samzong merged 2 commits into
mainfrom
fix/lathe-tool-directive

Conversation

@samzong

@samzong samzong commented Oct 4, 2026

Copy link
Copy Markdown
Contributor

What's changed?

  • Add tool github.com/lathe-cli/lathe/cmd/lathe to go.mod at lathe v0.6.3 and run go tool lathe bootstrap in cli-sync instead of go run ...@<pinned-version>.
  • Template default lathe_version is now v0.6.3; the replacement only touches go.mod because Makefile no longer carries a version.
  • Regenerate internal/generated and skills/appctl with lathe v0.6.3.

Why

  • The generator version was pinned in Makefile separately from the runtime in go.mod. Upgrading the runtime or replacing it with a local checkout left the generator on a different version, and the generated CLI failed to start. With the tool directive, one go.mod entry selects both.

Verification

  • Starter check and the CI git diff --exit-code set after cli-sync: clean.
  • lathe init --template <this branch> followed by the starter check passes with the v0.6.3 release binary, with LATHE_INIT_VERSION=v0.6.2 (generator and runtime both resolve to v0.6.2), and after go mod edit -replace github.com/lathe-cli/lathe=<local checkout> as in the Lathe release gate.

Signed-off-by: samzong <samzong.lu@gmail.com>
@ghfind-review ghfind-review Bot added the review: top ghfind author score; see https://ghfind.com label Oct 4, 2026
Signed-off-by: samzong <samzong.lu@gmail.com>
@samzong
samzong merged commit 9384d5c into main Oct 4, 2026
1 check passed
@samzong
samzong deleted the fix/lathe-tool-directive branch October 4, 2026 05:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

review: top ghfind author score; see https://ghfind.com

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant