Documentation
¶
Overview ¶
Command imagecheck fails when an image of the documentation site is broken. It reads every Markdown page under the given directory (docs by default), except the files that exclude_docs of the site's configuration (-config, mkdocs.yml by default) leaves out, collects the images outside code — `` and `<img src alt>` — and prints one line per problem, naming the page, the line and the image: a relative path that does not resolve to a file under the directory, an image without alternative text, and an image whose source is another site (http:, https: or //), which a reader's browser would load from that site. After reading every page it names each PNG under assets/screenshots/ that no page references, the output of make docs-screenshots that a page stopped using. It exits with 1 on a problem; make docs-check runs it before the build. A reference-style image — ![alt][ref], ![alt][] or ![ref], whose path a [ref]: definition gives — fails too, asking for an inline image, which the check can follow. References are matched line by line: an image whose alternative text wraps onto the next line and an <img> tag over several lines are not read.