Task: Implement the fleet command
This page documents a task in the compass cross-worktree status (global where) story. It captures the goal, current status, acceptance, and any notes or results.
Goal
Add a compass fleet subcommand that lists every git worktree with its
branch, mapped story + task (via the task #+branch: field), and open
PR (live state via gh), so parallel checkouts/agents don't collide.
Status
| Field | Value |
|---|---|
| State | DONE |
| Parent story | compass cross-worktree status (global where) |
| Now | Implemented and dogfooded across the live worktrees. |
| Waiting on | Nothing. |
| Next | Review. |
| Last touched | 2026-05-25 |
Acceptance
compass fleetlists every worktree fromgit worktree listwith branch, mapped story + task, and open PR + live state.- The branch → task mapping is read from each worktree's own tree
(the task
#+branch:field), so it works on unmerged branches. - The current worktree is marked; worktrees with no matching task (e.g.
main) are shown plainly. -f jsonemits a structured array; works offline (omits PR state).
Plan
list_worktrees(parsegit worktree list --porcelain).task_for_branch(per-worktree glob oftask_*.orgfor#+branch:).open_prs_by_branch(onegh pr listcall, matched byheadRefName).cmd_fleet+fleetsubparser; pretty + json output.
Notes
Dogfooded across the five live worktrees: local1 mapped to its story,
task and PR #828; PRs matched live by branch; the current worktree
flagged with →.
PRs
| PR | Title |
|---|---|
| #832 | [ores.compass] Implement compass fleet (worktree status) |
Review
| Comment summary | File | Decision | Notes |
|---|---|---|---|
Result
Implemented compass fleet in compass.py (cmd_fleet plus
list_worktrees / task_for_branch / open_prs_by_branch helpers and
the fleet subparser). Verified across the five live worktrees:
local1 → "ORE Studio Emacs dashboard" / its audit task / PR #828; this
worktree self-maps to this very task; the current worktree is marked
→; -f json emits the structured array. where / add unaffected;
py_compile clean.