mirror of
https://github.com/wu736139669/hapi.git
synced 2026-08-05 06:24:37 +00:00
fix(acp/runner): Cursor worktree banner + skip nested --worktree hang (#1087)
Ignore Cursor's Using worktree stdout banner without masking other non-JSON ACP frames (markClosed + kill). Skip --cursor-worktree when spawn directory is already a linked git worktree so ACP can initialize. Fixes #1085 Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -46,8 +46,10 @@ Set mode via `--mode` / `--permission-mode` / `--auto-review`, or change from th
|
||||
## Cursor-native worktree & multi-root
|
||||
|
||||
- New Session **Worktree** for Cursor uses Cursor's `--worktree` (`~/.cursor/worktrees/<repo>/<name>`), not HAPI's sibling-directory worktree.
|
||||
- Exception: if the spawn `directory` is **already** a linked git worktree (HAPI feature worktree, `driver/`, etc.), the runner does **not** pass `--cursor-worktree` — nesting hangs ACP initialize ([#1085](https://github.com/tiann/hapi/issues/1085)). Use the directory as cwd instead.
|
||||
- Mid-session: send `/worktree`, `/apply-worktree`, `/delete-worktree`, or `/add-dir <path>` (isolated pass-through).
|
||||
- CLI: `hapi cursor --cursor-worktree feature-x --cursor-add-dir ../shared`
|
||||
- ACP ignores Cursor's plain-text `Using worktree: …` stdout banner so remote `sessionType: worktree` can initialize (fixed in [#1085](https://github.com/tiann/hapi/issues/1085)). Other non-JSON ACP stdout remains a fatal protocol error.
|
||||
|
||||
## Slash pass-through (remote)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user