Skip to content

Docs: add/update repository documentation - #51

Merged
evandhoffman merged 1 commit into
mainfrom
docs/agents-and-readme
Sep 5, 2026
Merged

Docs: add/update repository documentation#51
evandhoffman merged 1 commit into
mainfrom
docs/agents-and-readme

Conversation

@evandhoffman

Copy link
Copy Markdown
Contributor

Summary

Reconciles README.md and AGENTS.md against the current repository, plus two stale files they depend on.

README.md gains the inventory it was missing. It documented monitor.app and monitord and never mentioned monitorctl at all, so a reader had no idea the third binary existed. It now carries:

  • a table of all three executables — what each is, and whether it ships in the release zip. monitorctl does not: Scripts/make-app.sh stages only monitor.app and monitord into .build/package.
  • a table of all five libraries, including MonitorLog, which the README had never mentioned either.
  • verified flag tables for both CLIs, taken from the @Option/@Flag declarations and confirmed against --help.
  • the CSV file-naming and rolling rules, and the build/test/CI section.

AGENTS.md keeps its structure and its hand-written Key Concepts. Corrections:

Was Now
"Only monitorctl prints" monitord prints its startup line, usage and version
Test list omitted CommandLineTests listed
CLI targets described as bare harnesses described as ArgumentParser commands, with their file names
ci.yml summary omitted the new smoke steps included
No mention of Package.resolved noted in Environment, and under Use Extra Caution as a lockfile

Added a Deprecated section (hand-rolled argument scanning with a usage literal; main.swift top-level code) and a Troubleshooting entry for the SourceRegistry.makeAll() cost that cost four minutes of test time.

docs/architecture.md said "Four libraries and two executables" and its diagram had neither MonitorLog nor monitord. Corrected to five and three, with a MonitorLog section. Package.swift's header comment omitted the same two targets.

Delivery mode

pr, not direct. The direct-mode criteria do not all hold: ci.yml triggers on pull_request, and every recent commit on main is a merge from a PR. (Single author and no branch protection do hold.)

Repository shape

Treated as a simple repository: one SwiftPM package, one swift build and one swift test covering every target, and no independently built or deployed component. One root AGENTS.md and one root README.md; no component-level files. CLAUDE.md and GEMINI.md were already symlinks to AGENTS.md and are unchanged.

Note on the AGENTS.md length budget

AGENTS.md is 593 lines, well over the ~150-line target, and I did not cut it to fit. Its Key Concepts section is the only place several load-bearing arguments are written down — grep over docs/ui.md finds no coverage of window totals, the computed time axis, tile zoom, or PanelArrangement. Trimming to budget would have deleted unique hand-written rationale rather than padding. Flagging it as a deliberate deviation; splitting Key Concepts into docs/ is a reasonable follow-up if you want the file shorter.

Inferred or uncertain

  • The "rolling at local midnight" description of the CSV files is read from CSVLogSink.receive (a new file opens when LogRetention.period changes) combined with the per-run filename. docs/roadmap.md describes it as "one file per day", which reads as inconsistent with monitord --help's "one per run"; both are true together, and I left roadmap.md untouched as out of scope.
  • Everything else is quoted from source, help text, scripts or CI config.

Not done

Nothing requested was blocked. Labelled release:skip: this touches Package.swift, which falls outside release.yml's docs-only path filter, so without the label a comment-only change would cut a release.

Reconciles both documentation surfaces against the repository. Treated as a
simple repository — one SwiftPM package, one build and one test command — so
one root AGENTS.md and one root README.md, no component files.

README.md gains the inventory it was missing. It documented monitor.app and
monitord and never mentioned monitorctl at all, so a reader had no idea the
third binary existed. It now lists all three executables with what each is and
whether it ships in the release zip (monitorctl does not; make-app.sh stages
only monitor.app and monitord), all five libraries, and the StampCommit
plugin. Both CLIs get their verified flags in tables, taken from the
declarations and confirmed against --help.

AGENTS.md keeps its structure and its hand-written Key Concepts, and fixes what
went stale:

- The logging note claimed only monitorctl prints. monitord prints its startup
  line, its usage and its version.
- The test list omitted CommandLineTests.
- The CLI targets are described as ArgumentParser commands, not bare harnesses.
- The ci.yml summary omitted the new help/version smoke steps.
- Package.resolved is called out as committed, in Environment and again under
  Use Extra Caution as a lockfile.
- A Deprecated section records the two patterns that are now gone: hand-rolled
  argument scanning with a usage literal, and main.swift top-level code.
- Troubleshooting gains the SourceRegistry.makeAll() cost, which cost four
  minutes of test time before it was found.

docs/architecture.md said "four libraries and two executables" and its diagram
had neither MonitorLog nor monitord. Corrected to five and three, with a
MonitorLog section. Package.swift's header comment omitted the same two.
@evandhoffman evandhoffman added the release:skip Merging this publishes no release label Sep 5, 2026
@evandhoffman
evandhoffman merged commit 99d351c into main Sep 5, 2026
2 checks passed
@evandhoffman
evandhoffman deleted the docs/agents-and-readme branch September 5, 2026 12:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release:skip Merging this publishes no release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant