A page that shows output the product does not produce teaches the wrong product. Three checks keep this book honest, and npm run build runs all three before it builds the site: a failing check fails the build.
| Check | What it guarantees | Run it alone |
|---|---|---|
| Transcripts | Every terminal session in the book runs against the real binaries, and prints what the page shows. | npm run check:transcripts |
| Reference | The command reference is exactly the binaries’ own help. | npm run check:reference |
| Provenance | Every verified page names the source it was checked against, and every name still exists. | npm run check:provenance |
The checks need af, af-server and af-runner. They look in the workspace’s target/debug and target/release; set FORGE_BIN to use binaries from somewhere else.
Transcripts
A transcript is a console code block, and each one says what happens to it:
| Block | Meaning |
|---|---|
```console server |
The one command af-server --dev. The checker starts a development server for the page and compares its banner. |
```console check |
The commands run in order, and each one’s output must match. |
```console eventually |
As check, for read-only commands that wait on the forge, such as a landing: each is retried until its output matches, for up to 15 seconds. |
```console background |
One command that runs for the rest of the page, as a runner does in a terminal of its own: the lines it prints first are compared, without ..., and it is stopped, with everything it started, when the page ends. Exiting before it printed them fails the page. background NAME names it, for a later stop. |
```console stop NAME |
The reader presses Ctrl-C in the terminal of NAME, a named background command or server. The block’s body is ^C, and what it stops must exit within 30 seconds. A server stopped so is started again, where it first ran, by a later server block. |
```console nocheck <reason> |
Not run. The reason is required. |
A page that runs more than one node gives the others the reader’s ports 7787 and 7788, 7797 and 7798, and 7807 and 7808. Each is the page’s own free port in the commands it runs, and is shown as the reader’s in what they print, as the first server’s are shown as 7777 and 7778.
In a block, $ starts a command and > continues it. Every other line is what the reader sees, standard output and standard error together:
```console check
$ af workspace add ~/hello
Workspace at /home/you/hello
Paths: **
main has no landing yet
```Write the output a reader really sees, IDs included. Commit IDs, change IDs, hashes and timestamps differ on every run, so the checker treats any hex run of seven or more characters as matching any other of the same length, and does the same for change IDs and for times, both RFC 3339’s and the 2026-01-31 12:00:00 form af file annotate prints, as jj’s annotate does. A line of ... stands for any number of lines, and [N] after a command’s output is its exit status when that is not 0.
Each page runs on its own, the way a reader works through it in one terminal: a fresh home directory, shown as /home/you; a fresh development server when the page starts one, shown on ports 7777 and 7778 whatever ports it really used; and blocks that run in order, sharing the working directory and exported variables. Git is set up as a reader’s would be, as You <you@example.com> with main as the first branch.
To write a new transcript, draft the commands with ... as their output and run the checker with --print: it prints what each command really printed, ready to paste.
node tools/check-transcripts.mjs --print start/quickstartReference
Pages under reference/ are generated from the binaries’ --help. Never edit them: change the help text in the binary’s source, rebuild it, and run npm run gen:reference.
Provenance
Each page’s frontmatter says what its claims rest on:
status |
Meaning |
|---|---|
verified |
Checked against the source files listed in verifiedAgainst, paths relative to code/compiler/rust. Its transcripts run. |
provisional |
Written, but not yet checked against the source. The default. |
planned |
Describes work that is not built yet, and says so. |
When a cited file moves, do not just rewrite the path. The field records that somebody checked; read the page against the new file, or mark it provisional.