Skip to content

docs: every documented command parses, and the site's terminals match the CLI - #20

Merged
pyjeebz merged 1 commit into
mainfrom
docs/match-the-cli
Nov 3, 2026
Merged

pyjeebz merged 1 commit into
mainfrom
docs/match-the-cli

Conversation

@pyjeebz

@pyjeebz pyjeebz commented Nov 3, 2026

Copy link
Copy Markdown
Owner

Closes #9.

The last Phase 1 item before v0.2.0. The docs and landing page now show what the CLI really prints, and a test keeps them from drifting again.

A check, not a promise. New TestDocumentedCommandsParse reads every ports … line inside a code block in the README and web/content/docs/*.mdx, which is currently over 20 lines. It resolves each one against the real command tree: the command exists, every flag belongs to that command, and the argument count is right. It runs no scan and sets no flags. TestParseDocumented proves it fails on each kind of drift a rename leaves behind:

  • a command that doesn't exist (frees);
  • another command's flag (kill --watch);
  • a misspelled flag;
  • a missing or extra argument;
  • a flag missing its value.

All documented commands pass today.

Copy that had drifted:

  • Commands page. The description said "Four commands, a doctor, a diff". It now reads "Every command, flag, and exit code — the whole tool on one page."
  • Landing tables (hero, one-binary, the showcase terminals) show project names (shop, admin), as the CLI's table does since table: projects read as their names, with just enough path to tell two apart #18. The doctor header, the resolution tree and the pipelines keep paths, because the CLI keeps them there too.
  • The kill showcase said ✓ stopped PostgreSQL (container shop-db). What kill prints is ✓ stopped PostgreSQL (:5432).
  • The doctor showcase gains ✓ responds to HTTP → http://localhost:3000, which real doctor prints for a web server.

The README and docs tables were already re-rendered to real output in #18, and the --expect and exit-code docs were updated in #17 and #19.

How it was verified

  • Go gate, locally with CI's versions: unit ✓, build ✓, integration ✓, installers ✓, gofmt ✓, vet ✓, lint ✓.
  • Site (web/, which CI doesn't check): npm run lint ✓, npm run build ✓ (all 15 routes). I served the build and checked that the hero row's PROJECT cell renders shop.

Risk

Tier: standard (docs, site copy and a test).
Rollback: revert the squash commit.
Needs a site deploy (vercel --prod from web/) to reach ports.tools. That's best done together with the v0.2.0 release (#10), so the site and the binary go live together.


Generated by Claude Code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

docs: bring site copy and examples in line with the shipped CLI

2 participants