Skip to content
Edith

Docs

Command reference

ed

Names a machine as the first word of the line and runs the rest there. ed rewrites the line before anything else, then the ordinary ed machines exec runs.

Output
ed <machine> <command...>ed <machine>

The rewrite happens in this order, and stops at the first rule that applies:

When the first word The line becomes
is missing, or starts with - unchanged
is machines reordered by the machine-first rule below
is a top level command name or alias, or help, or __complete unchanged
does not match a configured machine name or ssh alias unchanged
matches a machine, and something after it does not start with - machines exec <machine> -- <rest>
matches a machine, and the rest is empty or all flags machines show <machine> <rest>

The match against your machines is by whole name or whole ssh alias, case-insensitively. It is deliberately stricter than the resolver ed machines exec then uses: a prefix or an ID is not enough to trigger the shorthand, so ed dev uptime is not rewritten and fails as an unknown command with exit 2, while ed devbox uptime and ed 'Build Server' uptime both run.

The reserved list that wins over a machine name is every top level command and alias: guide, schema, version, completions, install, uninstall, config, app, extensions, permissions, usage, menu-bar-stats, music, nowplaying, np, calendar, tools, running-apps, download, downloads, dl, clipboard, color, colour, shelf, cleaner and machines, plus help and __complete. A machine called usage is unreachable by the shorthand and has to be named explicitly, as ed machines exec usage -- ... or ed machines show usage.

Because the rewrite inserts -- after the machine name, every flag after it belongs to the machine, never to ed. That is what lets ed devbox ls -la and ed devbox docker compose up -d work without ceremony, and it is why --tty has no shorthand: write ed machines exec --tty devbox top.

ed devbox docker ps runs the machine's own docker binary and prints its raw output. The parsed, --json version is ed machines docker ps devbox, which is a different command. Both are correct; the shorthand is always the raw one.

The machine-first spelling under ed machines

A word straight after machines that is not one of the group's subcommands is treated as the machine and moved to wherever the subcommand wants it. ed walks as far down the subcommand tree as the words allow, then inserts the machine after the last subcommand it consumed:

Output
ed machines devbox uptime            ed machines exec devbox -- uptimeed machines devbox docker ps         ed machines docker ps devboxed machines devbox files ls /etc     ed machines files ls devbox /etced machines devbox run ls -la        ed machines run devbox -- ls -laed machines devbox                   ed machines show devbox

Unlike the top level shorthand this does not check your machine list at all, so a typo is still moved into the machine slot and the error names it rather than complaining about an unknown subcommand:

Output
$ ed machines nosuchbox uptimeerror: no machine named nosuchboxhint: known machines: Devbox; machines subcommands: add, broadcast, connect, disconnect, docker, edit, exec, files, forward, forwards, kill, list, ls, metrics, power, remove, rm, run, services, show, snippet, snippets, workspace, workspaces

A subcommand name always wins. The names that cannot be used as a machine here are ls, list, show, add, edit, rm, remove, forwards, forward, snippets, snippet, power, workspace, workspaces, broadcast, kill, metrics, exec, run, files, docker, services, connect and disconnect. A machine literally called docker needs ed machines show docker.

Examples

Output
ed devbox uptimeed devbox systemctl status nginxed devbox 'ls -la /srv | head'ed machines devbox docker compose ls

Behaviour notes

A bare machine name is a lookup, not a shell:

Output
$ ed devboxDevbox  target   devbox · you@192.0.2.12  auth     SSH agent  system   Linux 7.0.0-28-generic x86_64  uptime   22:25:13 up  9:17,  5 users,  load average: 0.03, 0.08, 0.21  session  you on seat0 since 2026-08-08 13:08 (login screen)  session  you on tty2 since 2026-08-08 13:08 (tty2)

Flags alone count as nothing runnable, so ed devbox --json is ed machines show devbox --json rather than an attempt to run --json on the machine.

Where to go next