[PR #12572] feat(tui): improve session fork UX #14274

Open
opened 2026-02-16 18:19:05 -05:00 by yindo · 0 comments
Owner

Original Pull Request: https://github.com/anomalyco/opencode/pull/12572

State: open
Merged: No


What

  • Add a visible "Fork" action in the session header.
  • Add a "Fork current session" option to the fork dialog.
  • Improve feedback/toasts and prevent double-submits when forking.

Why

Forking currently feels like it might be switching sessions rather than creating a new one, and the quickest/common intent (fork current state) requires selecting a specific message. This makes discovery and confidence worse.

How

  • Header: provide a direct entrypoint for forking via session.fork.
  • Fork dialog: add a synthetic "current session" option with a unique value to avoid collisions.
  • Clear dialogs before awaiting async fork calls to avoid double-submits.

Tests

  • cd packages/opencode && bun run typecheck
  • (sanity) cd packages/opencode && bun test test/keybind.test.ts

Closes #12580

**Original Pull Request:** https://github.com/anomalyco/opencode/pull/12572 **State:** open **Merged:** No --- ## What - Add a visible "Fork" action in the session header. - Add a "Fork current session" option to the fork dialog. - Improve feedback/toasts and prevent double-submits when forking. ## Why Forking currently feels like it might be switching sessions rather than creating a new one, and the quickest/common intent (fork current state) requires selecting a specific message. This makes discovery and confidence worse. ## How - Header: provide a direct entrypoint for forking via `session.fork`. - Fork dialog: add a synthetic "current session" option with a unique value to avoid collisions. - Clear dialogs before awaiting async fork calls to avoid double-submits. ## Tests - `cd packages/opencode && bun run typecheck` - (sanity) `cd packages/opencode && bun test test/keybind.test.ts` Closes #12580
yindo added the pull-request label 2026-02-16 18:19:05 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#14274