reindex-docs
Regenerate generated docs/*.md index files and check whether AGENTS.md guidance needs follow-up. Use after adding, removing, renaming, or reordering docs collections or docs headings, especially when
SKILL.mdskills/reindex-docs/SKILL.md
GitHubReindex Docs
Purpose
Keep the generated docs/*.md index files in sync with the folder-local index.json files under docs/.
Inputs
None. The script discovers all folders under docs/ that contain an index.json file.
Workflow
Run the script from the repo root:
npx nx run @pz-web/skills:reindex-docsThe script rewrites the full generated index files. Keep human-written guidance in
docs/README.md, not in generated index files.Review the diff with
git diff.If
docs/conventions/**ordocs/decisions/**changed, compare the updated docs againstAGENTS.md:- Check whether the routing table, required-read list, skill list, or project guidance should mention the changed convention or decision.
- Suggest a concrete
AGENTS.mdupdate when the generated docs reveal new or renamed agent-facing guidance. - State explicitly when no
AGENTS.mdupdate appears necessary.
Commit the generated indexes and any requested follow-up edits.
Collections
docs/conventions/: H2 rule index, ordered by numeric prefix descending.docs/decisions/: file index, ordered by numeric prefix descending.docs/instructions/: file index, ordered by most recent git change date when no numeric prefixes are used.
Notes
docs/README.mdstays hand-written and intentionally shallow.- The
testtarget checks only index freshness.