SpecsCLIIssue 11 Scaffold Wiki Fumadocs Routing
Issue 11 Scaffold Wiki Fumadocs Routing Implementation Notes
Issue 11 Scaffold Wiki Fumadocs Routing Implementation Notes
Result
The scaffolded wiki template now includes scripts/sync-content.mjs and runs it before build and check-types.
The script projects existing source material into Fumadocs-readable content/docs folders, writes recursive meta.json files for copied trees, and tolerates app-root deploys where monorepo docs/ is absent by leaving checked-in routed content in place.
The existing Harness wiki probe exposed and fixed these update-path issues:
- Existing wiki
package.jsonfiles did not receive the new sync hook. - Existing managed
scripts/sync-content.mjsfiles would not update on rerun. - Scaffolded folder routes could collide with existing flat routed pages such as
repo-guidance.mdx. - Sync initially overwrote existing routed pages with root source docs.
- Projected root docs without frontmatter could pass type generation and fail production build.
- Generated
meta.jsonoutput needed to matchoxfmtformatting. dp updateoriginally ignored wiki seed/projection drift because the wiki came fromscaffold init, outside the setup manifest.
Files
apps/cli/src/content/wiki.tsapps/cli/src/scaffold/stage.tsapps/cli/src/scaffold/stage.test.tsapps/cli/src/update/run.tsapps/cli/src/update/run.test.tsapps/wiki/scripts/sync-content.mjsapps/wiki/package.jsondocs/README.mddocs/runbooks/dp-cli-scaffolding.mdapps/wiki/content/docs/project/runbooks/dp-cli-scaffolding.mdapps/wiki/content/docs/project/tech-debt/cli/scaffold-wiki-fumadocs-routing.md
Validation
bun run test --filter=@punks/cli -- scaffold/stage.test.tsbun run test --filter=@punks/cli -- update/run.test.ts scaffold/stage.test.tsbun run check-types --filter=@punks/clibun run check-types --filter=@punks/wikibun run build --filter=@punks/wikibun run check --filter=@punks/cli --filter=@punks/wikigit diff --check