Skip to content

add agtermctl version and teach the agent skill the cookbook - #476

Merged
umputun merged 3 commits into
masterfrom
cookbook-skill-and-version
Aug 21, 2026
Merged

add agtermctl version and teach the agent skill the cookbook#476
umputun merged 3 commits into
masterfrom
cookbook-skill-and-version

Conversation

@umputun

@umputun umputun commented Aug 21, 2026

Copy link
Copy Markdown
Owner

the bundled agent skill knew the cookbook only as a bare URL in examples.md, so an agent asked to list recipes or set one up had nothing to work from. It also had no way to check a recipe's minimum version, since agtermctl reported none and $TERM_PROGRAM_VERSION never reaches a keymap- or palette-launched process, which is how a recipe normally runs.

agtermctl version reports which agterm is serving the socket. App-global: no target, no --window, and no window need be open. One AppIdentity is built in the app target from Bundle.main and injected into ControlServer, feeding tree.app, the command, and each spawned terminal's TERM_PROGRAM_VERSION from a single value, so the three cannot drift apart. commit rides beside the version as diagnostics and is never part of a comparison.

human output adds a client: line naming the resolved path of the agtermctl that ran, which catches a stale CLI ahead of the bundled helper on PATH. That line is human output only; --json stays the raw response.

cookbook.md carries no recipe names. It resolves master to a commit SHA, reads the index at that SHA, resolves a requested name only against links in that index, and materializes from the same SHA, so the index read and the payload copied come from one tree and no URL is ever assembled from a name. Installing follows the recipe's own Setup: read each file first, add only if absent, stop and ask on a duplicate command or an occupied chord. It also covers reading a recipe as reference for a tricky workflow rather than installing it.

two doc drifts fixed along the way: SKILL.md claimed the tree had five top-level fields and site/commands.html claimed seven, where it has twelve.

recipes check a minimum agterm version and nothing exposed one. $TERM_PROGRAM_VERSION does not reach
a keymap- or palette-launched process, so a recipe preflight had no source at all. One AppIdentity,
built in the app target and injected into ControlServer, feeds tree.app, version, and the spawned
terminal's TERM_PROGRAM_VERSION, so the three cannot drift apart.
the skill mentioned the cookbook once, as a URL, so an agent could neither list recipes nor install
one. cookbook.md holds the mechanism and no recipe names, since the list lives in the repo and
changes independently of the skill. Installing merges rather than replaces, and acquisition pins to
one commit SHA so the index read and the payload copied come from the same tree.
reuse the shared CLI request path, pin cookbook.md in the bundle test, and restore version tests to their own sections. Keep the website result catalog in sync with result.app.
Copilot AI lite review requested due to automatic review settings August 21, 2026 07:25

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@umputun
umputun merged commit 5d22904 into master Aug 21, 2026
8 checks passed
@umputun
umputun deleted the cookbook-skill-and-version branch August 21, 2026 07:47
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.

2 participants