Allow finishing one known agent session#463
Merged
NagyVikt merged 2 commits intoApr 29, 2026
Merged
Conversation
added 2 commits
April 29, 2026 21:49
Add gx agents files, diff, and locks commands so a selected agent branch can be inspected without mutating the lane. The CLI resolves branch base metadata, uses the selected worktree when available, includes dirty worktree paths, and filters lock registry noise from file/diff output. Constraint: Commands must be read-only and cockpit-compatible. Rejected: Shelling out to the lock script for locks | JSON output and cockpit reuse need structured data from the registry. Confidence: high Scope-risk: narrow Directive: Keep agent inspection read-only; do not route these commands through finish or cleanup flows. Tested: node --test test/agents-inspect.test.js test/agents.test.js Tested: node --check src/agents/inspect.js && node --check src/cli/args.js && node --check src/cli/main.js
The agents CLI already has session metadata and branch finish plumbing, so this adds a small resolver that updates session status around the existing finish command instead of duplicating merge behavior. Constraint: Must reuse existing gx finish / branch finish logic Rejected: Reimplement branch finish in agents module | would fork merge semantics Confidence: medium Scope-risk: narrow Tested: node --test test/agents-finish.test.js Not-tested: live GitHub PR merge flow for gx agents finish
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Automated by gx branch finish (PR flow).