---
name: Editor Command for Worktrees
---

# Story 37: Editor Command for Worktrees

## User Story

As a user supervising multiple agents working in worktrees, I want to configure my preferred editor (e.g. Zed, VS Code, Cursor) so that agents can give me a ready-to-paste command like `zed ~/workspace/foo/bar/story-45-worktree` to quickly open a worktree in my editor.

## Acceptance Criteria

- [ ] User can configure a preferred editor command (e.g. `zed`, `code`, `cursor`) via the API
- [ ] Editor preference is persisted across server restarts
- [ ] API endpoint returns a formatted open-in-editor command for a given worktree path
- [ ] The UI displays a copy-paste-ready editor command for each active worktree
- [ ] Agents can retrieve the editor command for a worktree they're working in

## Out of Scope

- Actually launching the editor from the server (just provide the command string)
- Editor plugin/extension integration
- Detecting installed editors automatically
