From d7c75644156cc1432cd769a72d00e6d875d17b5b Mon Sep 17 00:00:00 2001 From: Devvyn <22340871+opticon454@users.noreply.github.com> Date: Sun, 11 Oct 2026 11:16:32 +0800 Subject: [PATCH] fix(copilot): declare a composer ready mark so codeman agent spawn waits for it MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Copilot had no composerReadyMark, so `codeman agent spawn --mode copilot` returned as soon as the session existed, before the composer could take a prompt (and before folder trust was answered). The mark is the composer's footer hint, not the glyph: the trust dialog draws `❯ 1. Yes`, so `❯` would call a worker ready while it still asks for trust. Measured on 1.0.95: the dialog footer reads `↑/↓ to navigate`, the composer's reads `/ commands · ? help`. --- src/config/cli-registry/stock.ts | 5 +++++ test/cli-agent.test.ts | 2 ++ 2 files changed, 7 insertions(+) diff --git a/src/config/cli-registry/stock.ts b/src/config/cli-registry/stock.ts index 5793b969..1a130918 100644 --- a/src/config/cli-registry/stock.ts +++ b/src/config/cli-registry/stock.ts @@ -1757,6 +1757,11 @@ const COPILOT: CliEntry = { // `_shouldForwardWheelToApp` forwards it as SGR reports while the CLI is tracking. altScreen: 'strip-mux-and-mouse', echo: { policy: 'buffer', anchor: { kind: 'cursor' } }, + // What `codeman agent spawn` waits for. The composer's footer hint, NOT the `❯` glyph: the + // folder-trust dialog draws `❯ 1. Yes` for its selected row, so the glyph would call a worker + // ready while it is still asking for trust (measured on 1.0.95: the dialog's footer reads + // `↑/↓ to navigate`, the composer's `/ commands · ? help`). + composerReadyMark: '/ commands · ? help', // The composer row is a `❯` between two rules, and the submitted prompt is echoed as // ` ❯