support session listing and loading #263
Open
+626
−49
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.
Summary
This PR improves ACP session startup behavior and session selection UX.
It adds strategy-based session loading (
latest,prompt,new), supports loading existing sessions when the agent advertisessession/list+session/load(codex-acp for example), and has ** Start a new session ** as default.What Changed
agent-shell-session-load-strategy(latestdefault,prompt,new).session/list.session/load.new, attemptsession/listthensession/load.session/newon list/load errors or when no session is selected.title | updatedAt | sessionId).Tests
Added/updated ERT coverage for:
session/newwhensession/listfails.newstrategy bypassing list/load.Targeted test run for these flows passes.
Docs / Follow-up Included in Branch
This branch also includes small documentation updates:
agent-shell.el.agent-shell-session-load-strategy.Checklist
M-x checkdocandM-x byte-compile-file.