Documentation
¶
Overview ¶
Command doccomments fails on comments and docs that break the house style, so godoc, editors and GitHub show them as written. In Go comments it fails on:
- a top-level comment attached to no declaration, e.g. a doc comment split from its declaration by a blank line, of which godoc shows only the part next to the declaration
- a character that isn't ASCII or in .vscode/maths.code-snippets, which includes em dashes
- a semicolon in a prose line, as plain English has no place for one
- an unpaired ', " or backtick on an indented line, which godoc shows as code, and which an editor's hover highlights as an unclosed literal
In markdown it fails on a character that isn't ASCII or in the snippets, anywhere, and on a semicolon in prose, outside code blocks and inline code.
It reads every .go and .md file outside hidden directories, temp and testdata.
go run ./cmd/doccomments