Skip to content

docs(cli): turn CLI_REFERENCE into an index of the command group pages - #5198

Merged
dan-petty merged 4 commits into
mainfrom
docs/5163-turn-cli-reference-into-an-index
Nov 12, 2026
Merged

dan-petty merged 4 commits into
mainfrom
docs/5163-turn-cli-reference-into-an-index

Conversation

@dan-petty

Copy link
Copy Markdown
Owner

docs/CLI_REFERENCE.md is now a short generated index: one row for each command group, with its one-line help and a link to its page in docs/commands/, and then the command matrix. The full text of each command stays on the page of its group, which now also holds the group description. The page falls from 421,673 to 56,887 characters.

The matrix moves out of README.md, which links the index. devops docs sync-readme, --sync-readme and --check-readme are deleted with no shim. devops ci docs --fix, the implement job and the stage plan text run devops docs generate. The site tab opens on the index.

Each living file that named --sync-readme names devops docs generate. Records keep the old name, and ADR 0025 gets a note.

Closes #5163

Change: openspec/changes/archive/2026-11-12-5163-turn-cli-reference-into-an-index/

docs/CLI_REFERENCE.md is now a short generated index: one row for each
command group with its one-line help and a link to its page in
docs/commands/, then the command matrix. The full text of each command
stays on the page of its group, which now also holds the group
description.

The command matrix moves out of README.md, and README.md links the
index. devops docs sync-readme, --sync-readme/--no-sync-readme and
--check-readme/--no-check-readme are deleted with no shim. devops ci
docs --fix, the implement job, its request plan, the stage plan text
and the scaffold checklist run devops docs generate. The CLI reference
tab of the docs site opens on the index.
@dan-petty dan-petty added type/docs Type docs: a change to the documents scope/cli Core CLI framework, Typer subcommands, options, and tables labels Nov 12, 2026
@dan-petty

Copy link
Copy Markdown
Owner Author

Notes for the review of this pull request.

Proof (head a21263d63, rebased on 050a6ef72)

  • uv run devops ci test tests/docs tests/github/test_github_pages.py tests/commands/test_config_workspace_docs_dry_run.py tests/commands/test_ci_dry_run.py tests/commands/test_new.py: 165 passed.
  • uv run devops ci test tests/roadmap tests/commands/test_roadmap_eval_implement.py before the rebase: 7,145 passed after the fixture update of good-3264. After the rebase, the 7 changed or related roadmap modules: 497 passed.
  • The 6 new tests failed before the change (index rows, group description, no README option, README link, generator writes no README.md, nav of the CLI reference tab).
  • uv run devops docs check: all documentation files are up to date.
  • uv run --all-groups devops docs site build --strict (Zensical 0.1.1): 108 pages, "No issues found". The built index links ../commands/repos/.
  • ruff check, ruff format --check and mypy on the changed src/ files pass.

#4781

#4781 is open and has no pull request. It changes _commit_if_changed in src/devops_cli/roadmap/implement/implement_run.py. This pull request edits only the argv of _generate_docs in that file (docs generate with no --sync-readme), so the two changes touch different lines, and #4781 can build on either order.

Other notes

  • The implement job runs the devops of its checkout. A runner image from before this change stops at the docs step on a main that has this change, until the image of this change rolls out.
  • feat(docs): generated pages name their source and stay complete #4889 plans one generalized marker-block function for the README matrix and the docs/index.md list. With no README block left, that function has one caller fewer.
  • The records keep --sync-readme: 589 archived change files, 14 files in 9 active change folders (a builder ticks those task lines, so an edit here would conflict with that branch), 75 eval fixtures, the ADRs 0010 and 0014, the agent archive, the log excerpt of fix(roadmap): a job runs a project step only where the repo has it #3484 and one recorded refused finding.

@dan-petty
dan-petty force-pushed the docs/5163-turn-cli-reference-into-an-index branch from a21263d to 8c583bc Compare November 12, 2026 20:11
@dan-petty

Copy link
Copy Markdown
Owner Author

Fix for the failure of Tests & Coverage (shard 1 of 4) on a21263d63: tests/invariants/test_agents_md.py::test_every_hand_written_and_generated_document_is_within_two_links_of_agents_md listed the 43 pages of docs/commands/. They were two links from AGENTS.md through the README matrix, and with the index they were three.

Commit 73583698f adds a link to docs/CLI_REFERENCE.md in the command row of the "Where to look" table of AGENTS.md. AGENTS.md had 6,488 of its 6,500 characters (CONST_AGENTS_MD_MAX_CHARS), so the row of the knowledge base drops devops <command> --help: the group pages hold the same text. AGENTS.md now has 6,496 characters.

Proof: uv run devops ci test tests/invariants 807 passed. The tests that read AGENTS.md (tests/commands/test_instruction_generator.py, tests/commands/test_ai_cmd.py and two review modules) 88 passed.

@dan-petty
dan-petty marked this pull request as ready for review November 12, 2026 20:19
@dan-petty
dan-petty merged commit 0a14161 into main Nov 12, 2026
25 checks passed
@dan-petty
dan-petty deleted the docs/5163-turn-cli-reference-into-an-index branch November 12, 2026 20:29
dan-petty added a commit that referenced this pull request Nov 15, 2026
Pull request #5198 deleted the option --sync-readme of devops docs
generate, and ADR 0010 and ADR 0014 still named it as the command that
regenerates the documents, so an agent that follows them gets a usage
error. Each record gains one dated Status History line: the option is
deleted, so the command is devops docs generate. The body stays as it
is, because an accepted record changes only in the front matter and a
dated Status History line.

Closes #5244

Change:
`openspec/changes/archive/2026-11-15-5244-drop-the-deleted-sync-readme-option/`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

scope/cli Core CLI framework, Typer subcommands, options, and tables type/docs Type docs: a change to the documents

Projects

None yet

Development

Successfully merging this pull request may close these issues.

docs(cli): turn CLI_REFERENCE into an index of the command group pages

1 participant