# ed code-review

> Discover and open Quinjet review workspaces through the same client, worktree selection and launch-request builder as Edith's Code Review page.

- Canonical URL: https://getedith.pro/docs/cli/code-review
- Updated: 2026-12-02

Discover and open Quinjet review workspaces through the same client, worktree
selection and launch-request builder as Edith's Code Review page. Discovery can run
against this Mac or one configured SSH machine.

`ed code-review` defaults to `ed code-review projects`. A local or remote Quinjet CLI
must be installed and able to return its current JSON format. The Edith Code Review
extension does not have to be enabled for discovery and standalone launch. The
review inbox and parent board commands need the enabled extension and the GitHub
CLI signed in to github.com on this Mac.

## At a glance

| Command | What it does |
| --- | --- |
| `ed code-review projects` | List recent projects and their worktrees |
| `ed code-review worktrees <path>` | List every worktree for a project or worktree path, with local change status |
| `ed code-review inbox` | List pull requests waiting on you or your teams |
| `ed code-review inbox-open <id>` | Recheck an inbox pull request and open it in a review session |
| [`ed code-review parent-board <owner/repository> --parent <branch>`](https://getedith.pro/docs/cli/code-review/parent-board) | Show open and landed task pull requests for one parent branch |
| `ed code-review open <path>` | Print the exact launch command without running it |
| `ed code-review launch <path>` | Run a standalone Quinjet process in the current terminal or cmux |
| `ed code-review status [session]` | Show one native session in the running Edith page |
| `ed code-review sessions` | List the native sessions in the running Edith page |
| `ed code-review new` | Create and select a native picker tab |
| `ed code-review focus <session>` | Select a native tab and focus its cmux workspace when applicable |
| `ed code-review close <session>` | Preview or close a native tab and its cmux workspace |
| `ed code-review restart [session]` | Restart a native review in the same tab |
| `ed code-review switch <session> <path>` | Switch a native tab to another worktree |

## Targeting

Discovery, launch and native session commands accept `--machine <name>`. Omit
it, or use `--machine local`, for this Mac. A configured machine name, SSH alias, UUID or unique prefix resolves
through Edith's machine directory. The command connects through Edith's shared
SSH control socket and gives that socket to Quinjet for remote discovery and
launch.

```sh
ed code-review projects --json
ed code-review projects --machine build --json
ed code-review worktrees /srv/storefront --machine build --json
```

A machine that is asleep or unreachable exits 4 before discovery. An unknown
machine exits 3.

The native machine picker uses these same project and worktree reads. Its folder
browser corresponds to `ed machines files ls <machine> <path>`, so Quinjet does
not duplicate the general remote filesystem command.

## Planning and launching

`ed code-review open` is print-only. It resolves the requested project, chooses the
current or first available worktree, constructs the launch request and prints a
shell-quoted command. It never starts a process or sends AppleScript.

`ed code-review launch` crosses the standalone execution boundary. The default
starts an interactive Quinjet process attached to the same standard input and
output. `--cmux` asks cmux to create a workspace instead. It does not create or
control a tab in Edith's native Code Review page.

```sh
ed code-review open ~/code/storefront
ed code-review open ~/code/storefront --theme tokyo-night --appearance light
ed code-review launch ~/code/storefront
ed code-review launch ~/code/storefront --cmux
ed code-review launch /srv/storefront --machine build --theme gruvbox
```

Both commands accept these options:

| Name | Values | Default | What it does |
| --- | --- | --- | --- |
| `--theme <name>` | `quinjet`, `catppuccin`, `dracula`, `everforest`, `gruvbox`, `nord`, `one`, `rose-pine`, `solarized`, `tokyo-night`, `ayu`, `monokai`, `github` | saved app theme | Select the Quinjet theme |
| `--appearance <value>` | `light`, `dark` | current app appearance | Select the theme appearance |
| `--cmux` | flag | saved app terminal | Force a cmux launch request |
| `--embedded` | flag | saved app terminal | Force a current-terminal launch request |
| `--machine <name>` | configured machine or `local` | `local` | Select the worktree host |
| `--json` | flag | off | Emit stable JSON on stdout |

The app's terminal and theme menus persist through
`ed config set codeReviewTerminal embedded` and `ed config set codeReviewTheme <name>`.
Set `codeReviewTheme` to `app` to send Edith's active light and dark palettes to
Quinjet automatically. A named Quinjet theme remains an explicit override and
the app discovers available names from the installed Quinjet version.

cmux must be installed in `/Applications`. If it is not,
`launch --cmux` exits 4 with a hint to omit `--cmux`. `open --cmux` remains safe
and prints the cmux-targeted Quinjet command without asking cmux to run it.

## Native sessions

These commands need the Code Review extension enabled and its page open. Run
`ed app reveal codeReview` before using them. A silent or older app exits 4 instead
of waiting indefinitely.

Each session can be selected by its 1-based number, full id, exact title, exact
branch, or current worktree path. Shell completion asks the running page for
session numbers with a 250 millisecond bound.

```sh
ed code-review sessions
ed code-review status
ed code-review new
ed code-review focus 2
ed code-review restart 2
ed code-review switch 2 ~/code/storefront-checkout
ed code-review close 2
ed code-review close 2 --yes
```

`new`, also available as `create`, adds and selects a picker tab through the same
app-side operation as the tab bar plus button. `focus` selects the tab in Edith.
For a cmux-backed session it also activates the
matching cmux workspace. `close` prints a non-mutating plan unless `--yes` is
present. A confirmed close terminates the embedded process or closes the exact
cmux workspace before removing the tab. Edith keeps at least one picker tab, so
the only native session cannot be closed.

`restart` preserves the tab id, machine, worktree and saved launch configuration.
`switch` resolves the new worktree through the same local or remote Quinjet
client used by the picker, then replaces the review in the same tab. Both route
through the same app-side operation method used by the corresponding buttons.

## Worktree status

On this Mac, `ed code-review worktrees` runs one read-only `git status` per
worktree, at most four at a time, using the `git` found on your tool path. Git
runs with optional locks and filesystem monitoring disabled, so reading status
never refreshes the index or rewrites worktree records, and it never searches
parent folders for another repository. The state column shows `clean`,
`uncommitted changes`, `missing folder` or `status unavailable` next to
`current`, `detached`, `locked` and `prunable`. A failed status read is reported
as unavailable, never as clean, and does not stop you from opening the
worktree. A missing folder does. Remote machines report no change status.

The worktree list in Code Review reads the same status when it opens, for the
worktrees it shows, and offers Show in Finder for each local worktree that can
be opened.

## Review inbox

`ed code-review inbox` lists open pull requests where you or one of your teams is a
requested reviewer, pull requests assigned to you, and your own open pull
requests. It uses the GitHub CLI account signed in to github.com and the
repositories chosen on the Home GitHub card. With no card, every repository you
can read is included. Each category loads up to 50 recently updated pull
requests, and the output says when more exist.

```sh
ed code-review inbox
ed code-review inbox --json
ed code-review inbox --repository example/app --kind review --filter search
ed code-review inbox-open PR_example
```

| Name | Values | What it does |
| --- | --- | --- |
| `--repository <owner/name>` | repository | Only show one repository |
| `--kind <kind>` | `review`, `assigned`, `authored` | Only show one reason |
| `--filter <text>` | text | Match titles, repositories, numbers, authors, labels and teams |
| `--json` | flag | Emit an array of pull requests on stdout |

`inbox-open <id>` takes an id from the last inbox refresh. It rechecks the
account, the open state and the reason the pull request is waiting on you, then
opens it with `quinjet tui --pr <number>` in the recent local project whose
GitHub `origin` matches. It never checks out the pull request branch. Running it
again for the same pull request focuses the session already showing it instead
of opening another. A pull request with no matching local project exits 3 and
asks you to open a local checkout first. A pull request that is no longer
waiting on you also exits 3. GitHub rate limits pause requests until the time
GitHub gives, and the last results stay on screen.

The Review inbox section of the Code Review page offers the same list, filters
and open action, and refreshes every two minutes while it is visible.

## JSON

`projects --json` returns `local`, `machine` and `projects`. Each project has
`commonDir`, `name` and `worktrees`. `worktrees --json` returns `local`,
`machine` and `worktrees`.

A worktree object has these stable keys: `bare`, `branch`, `canOpen`, `current`,
`detached`, `dirty`, `displayName`, `head`, `locked`, `missing`, `path`,
`prunable` and `statusError`. `dirty`, `missing` and `statusError` come from the
local status read and are null in `projects` output and on remote machines.
Nullable values are JSON null. Object keys are sorted.

`inbox --json` returns an array of pull requests with `id`, `repository`,
`number`, `title`, `author`, `url`, `updatedAt` (ISO 8601), `isDraft`,
`reviewDecision`, `checks`, `labels`, `roles` and `teams`. `roles` holds
`review`, `assigned` or `authored`. `teams` lists the requested teams, as
`organization/slug`, that put the pull request in your inbox. `inbox-open --json`
returns `repository`, `number`, `sessionID` and `reused`.

`open --json` and `launch --json` return `arguments`, `command`,
`currentDirectory`, `executable`, `launched`, `local`, `machine`, `terminal` and
`worktree`. `launched` is false for `open` and true after a successful `launch`.
`terminal` is `current` or `cmux`.

For `launch --json`, the child process cannot write to stdout and receives no
interactive input, so stdout remains exactly one JSON document. Use plain
`launch` for an interactive terminal session. Use `open --json` for a safe
noninteractive preview, or `launch --cmux --json` to open a separate workspace.

Native session JSON returns `operation`, `selectedSessionID`,
`affectedSessionID` and `sessions`. Each session has `id`, `index`, `title`,
`selected`, `state`, `terminal`, `project`, `worktreePath`, `branch`, `machine`,
`canClose`, `canRestart` and `exitMessage`. Nullable values are JSON null.

The JSON preview from `close` follows the shared destructive-plan contract with
`action`, `targets`, `applied` and `changed`. A confirmed close additionally
returns `closedSessionID`, `selectedSessionID` and `remaining`.

## Exit codes

| Code | When |
| --- | --- |
| 0 | Discovery, planning, launching or native session control succeeded |
| 1 | Quinjet failed, returned malformed JSON or exited unsuccessfully |
| 2 | Arguments, theme or appearance were invalid |
| 3 | The machine, worktree or native session was not found |
| 4 | Quinjet, cmux, the selected machine or the running Edith page was unavailable |

A missing Quinjet executable includes a hint to run `ed tools install quinjet`. A failed
Quinjet command includes its diagnostic. Malformed JSON suggests updating
Quinjet and retrying.

## Where to go next

- [`ed machines`](https://getedith.pro/docs/cli/machines) for configured SSH machines
- [`ed extensions`](https://getedith.pro/docs/cli/extensions) to show the Code Review page in Edith
- [All `ed` commands](https://getedith.pro/docs/cli)

## Get Edith

Edith is a native Mac app for macOS 14 or later on Apple silicon with 100+ extensions, the `ed` command line and an MCP server. $35 once for one Mac, plus $7 for each additional Mac, with no subscription and a 30-day refund.

- [Buy Edith](https://getedith.pro/pricing): $35 once for one Mac, plus $7 for each additional Mac
- [Download Edith](https://getedith.pro/download): the installer, or Homebrew
