Imported from tanaabased/codex-tools (
examples/AGENTS.md). Install upstream withnpx skills add tanaabased/codex-tools --skill examples. Copyright stays with the author.
Codex Tools Examples
The README files below examples/ are executable Leia scenarios consumed by pull-request CI.
They run the built dist/codex-tools executable and must use disposable state only. Local Leia
execution requires an explicit request.
Scenario style
- Use focused, behavior-named
# shouldblocks. Each blank-line-separated block runs in a fresh shell, so reconstruct state from files or keep dependent operations in one block. - Keep fixtures beside the scenario that owns them. The shared
fixtures/bincommands are the one exception: they model the Codex and npm child-process boundary used by install and refresh. - Use
TMPDIRfor mutable copies, logs, homes, caches, and generated state. Never mutate checked-in fixture sources or an operator's Codex home. - Assert observable output, exit status, or file state. A zero exit alone is not evidence of the behavior named by the block.
- Capture expected nonzero results before inspecting their output; do not weaken the workflow with
|| true.
Ownership
defaultsowns the unoverridden source and Codex-home defaults.inputsowns help, version, option forms, environment precedence, booleans, JSON/debug output, and invalid input.installowns local and npm installation journeys.refreshowns local cachebuster refresh and pinned npm refresh.statusowns the read-onlystatusanddoctorinterface.cacheowns drift reporting, dry runs, synchronization, and convergence.
The fake child commands prove Codex Tools orchestration, not native Codex or registry compatibility. Real Codex and npm integration stays in the isolated native-verification workflow.