Part of the distilled-docs spec (parent issue).
Why
The name is contradicted by the output. bin/lib/render.mjs claims in its header that /catalog/<name>.md sits next to the JSON, and test/turbo-cache.test.ts says the website build emits /catalog/*.{json,md} — but the script writes to apps/website/public/examples/. The word "catalog" no longer names anything the script emits.
"llms" names the audience instead, which is what unifies the three outputs: llms.txt, /examples/<name>.md, /examples/<name>.json, all served to the pmndrs docs MCP server and to rel="alternate" on every example page.
What
| From |
To |
bin/build-catalog.mjs |
bin/build-llms.mjs |
bin/lib/render.mjs |
bin/lib/render-llms.mjs |
test/render.test.ts |
test/render-llms.test.ts |
Eight real references to update:
turbo.json (the inputs list)
apps/website/package.json — dev and build scripts, twice
test/render.test.ts — the import and its @ts-expect-error comment
test/turbo-cache.test.ts — two withTouched(...) calls and the stale /catalog/*.{json,md} comment
bin/build-catalog.mjs — its own import of ./lib/render.mjs
apps/website/lib/helper.ts — a comment naming the script
- the two stale
/catalog/ mentions, corrected to /examples/
The copies under .claude/worktrees/ are separate checkouts. Leave them alone.
Notes
Pure refactor, no behaviour change. It goes first so nothing else has to rebase over a file move, and alone because it touches turbo.json inputs and so busts the cache once.
Done when
pnpm check and pnpm test pass, the built output is byte-identical to before the rename, and no /catalog/ string survives outside .claude/worktrees/.
How to implement
Start from a cleared session — this issue is written to be self-sufficient, and a session carrying the design discussion also carries the options that were rejected.
Branch off main. Nothing depends on it, and it goes first so nothing else rebases over a file move.
git checkout -b rename-build-llms
/mattpocock-skills:implement #193
implement commits to the current branch, so the branch has to exist first — otherwise this lands on main.
Part of the distilled-docs spec (parent issue).
Why
The name is contradicted by the output.
bin/lib/render.mjsclaims in its header that/catalog/<name>.mdsits next to the JSON, andtest/turbo-cache.test.tssays the website build emits/catalog/*.{json,md}— but the script writes toapps/website/public/examples/. The word "catalog" no longer names anything the script emits."llms" names the audience instead, which is what unifies the three outputs:
llms.txt,/examples/<name>.md,/examples/<name>.json, all served to the pmndrs docs MCP server and torel="alternate"on every example page.What
bin/build-catalog.mjsbin/build-llms.mjsbin/lib/render.mjsbin/lib/render-llms.mjstest/render.test.tstest/render-llms.test.tsEight real references to update:
turbo.json(theinputslist)apps/website/package.json—devandbuildscripts, twicetest/render.test.ts— the import and its@ts-expect-errorcommenttest/turbo-cache.test.ts— twowithTouched(...)calls and the stale/catalog/*.{json,md}commentbin/build-catalog.mjs— its own import of./lib/render.mjsapps/website/lib/helper.ts— a comment naming the script/catalog/mentions, corrected to/examples/The copies under
.claude/worktrees/are separate checkouts. Leave them alone.Notes
Pure refactor, no behaviour change. It goes first so nothing else has to rebase over a file move, and alone because it touches
turbo.jsoninputs and so busts the cache once.Done when
pnpm checkandpnpm testpass, the built output is byte-identical to before the rename, and no/catalog/string survives outside.claude/worktrees/.How to implement
Start from a cleared session — this issue is written to be self-sufficient, and a session carrying the design discussion also carries the options that were rejected.
Branch off
main. Nothing depends on it, and it goes first so nothing else rebases over a file move.implementcommits to the current branch, so the branch has to exist first — otherwise this lands onmain.