Documentation
¶
Overview ¶
Command checkdocs is the doc gate. It fails when a Markdown file in this repository cites something that is no longer there.
The docs anchor their claims to the source tree — `sdk/tasks/internal/vfs`, `cmd/root.go`, `TESTING.md#conventions`. Nothing else in the project checks those: a rename leaves the citation reading as if it were still true, and the reader follows a dead path. Four classes are caught:
- A `cmd/…` or `sdk/…` path that no longer exists on disk.
- A citation pinned to a LINE NUMBER (`path:42`, `path#L42`). It rots faster than the path ever does — it survives no edit above it — and this gate cannot see that it moved, because the file still exists. Cite the symbol instead: it is stable across edits, and it is greppable, which a line number is not.
- A relative Markdown link whose target file, or whose `#anchor` inside that file, does not resolve.
- An audience leak in docs/user-guide/ — a Go source path or a link into docs/specs/ on a page written for someone who never opens this repository (docs/DOCUMENTING.md owns that rule).
Class 3 reads its anchor table outside fenced blocks only: a `#` line inside a fence is an example or a shell comment, and GitHub mints no anchor for it.
Every spelling of a citation counts, fenced blocks included: a stale path in a code block misleads a reader exactly as far as one in prose.