orca/config
Trevin Chow 7361bff698
feat: rename worktree folder to match branch on first work (#4743)
* feat: rename worktree folder to match branch on first work

When the first agent message auto-renames a freshly created creature branch to a
short, work-derived name, also align the on-disk worktree folder and the sidebar
display name with it. Re-key every worktree-scoped slice of state — renderer
store maps plus the persisted main-process state — through the resulting id
change so the live worktree survives the rename instead of being treated as a
deletion (its tabs, terminals, browser panes, and git status all follow).

The rename is best-effort and local-only: a skip or failure (remote runtime,
Windows lock, destination taken) leaves the folder as-is and never undoes the
branch/display rename that already landed.

Squashed from the original PR #4743 commits, rebased onto upstream/main to drop
accumulated merge commits and i18n formatting churn so the branch carries only
the feature diff:
- Rename worktree folder to match branch on first work
- migrate renamed worktree session ids
- keep the live worktree alive through a folder rename
- address PR review feedback

* Address PR review feedback (#4743)

- orca-runtime: emit in-process worktreesChanged client event on folder rename, mirroring notifyBranchRenamed so onClientEvent listeners aren't left stale
- worktrees: re-key rightSidebarExplorerViewByWorktree and activeWorkspaceKey through a worktree-identity rename (both were worktree-scoped but missed by buildWorktreeRenameState)
- branch-name-from-work: treat prefix-only model output as an empty slug so the caller skips the rename instead of producing a doubled prefix
- worktree-folder-rename-target: document why posix.dirname is safe (Windows filtered out earlier)
- tests for each of the above

* Extract branch rename test helpers to a separate harness file

Move git responders, mock builders, and test event fixtures out of
first-work-branch-rename.test.ts into a new test harness file. This
reduces file length and removes the max-lines ESLint disable directive,
complying with project style guidelines.

* Wrap entire OnboardingFlow in TooltipProvider

Enable the use of tooltips anywhere within the onboarding flow, rather
than restricting them to the step indicators.

---------

Co-authored-by: Jinjing <6427696+AmethystLiang@users.noreply.github.com>
2026-06-15 19:58:55 -07:00
..
patches Fix terminal table rendering after workspace restore (#4877) 2026-06-08 03:25:55 -07:00
scripts Reduce Orca idle CPU (#5402) 2026-06-15 12:56:22 -07:00
dev-app-update.yml chore: move dev-app-update.yml into config/ (#1276) 2026-04-30 00:11:14 -07:00
electron-builder.config.cjs Fix Linux dock window class (#5293) 2026-06-12 19:13:19 -04:00
localization-audit.md Improve localization catalog sync workflow (#5110) 2026-06-10 11:13:01 -07:00
localization-coverage-allowlist.json Add English localization infrastructure (#4995) 2026-06-09 10:43:04 -07:00
oxlint-react-doctor.json chore: gate high-signal react doctor rules 2026-05-31 22:35:15 -07:00
oxlint-switch-exhaustiveness.json chore: enforce exhaustive switch handling 2026-05-30 13:18:12 -07:00
packaged-runtime-node-modules.cjs Add English localization infrastructure (#4995) 2026-06-09 10:43:04 -07:00
tsconfig.cli.json Revert Codex launch homes to shared runtime (#4400) 2026-06-01 12:36:16 -07:00
tsconfig.node.json feat(telemetry): PR 2 — transport (client, validator, burst cap, IPC, build gate) (#1374) 2026-05-03 16:51:31 -07:00
tsconfig.relay.json Support agent status hooks over SSH (#1865) 2026-05-14 16:06:23 -07:00
tsconfig.tc.cli.json refactor to clean up the codebase (#412) 2026-04-08 22:49:16 -07:00
tsconfig.tc.web.json feat: rename worktree folder to match branch on first work (#4743) 2026-06-15 19:58:55 -07:00
tsconfig.web.json chore: enforce exhaustive switch handling 2026-05-30 13:18:12 -07:00
vitest.config.ts Update onboarding feature wall experience (#2652) 2026-05-23 12:21:13 -07:00