Command reference
ed machines control
ed machines control exposes the live controls shown in the Machine Control
Center through the same operation definitions and command builder used by the
app. It works against configured SSH machines and against this Mac with the
reserved target local.
ed machines control status boxed machines control status box --jsoned machines control brightness box 60ed machines control volume box 35ed machines control mute box oned machines control wifi box offed machines control wifi box off --yesed machines control bluetooth box oned machines control airplane box on --yesed machines control dnd box offed machines control caffeinate box oned machines control keyboard-light box 25ed machines control status localThe machine-first form is equivalent:
ed machines box control statused machines box control volume 35Safety
Turning Wi-Fi off and turning airplane mode on may disconnect an SSH machine.
Those two changes only print a preview unless --yes is present. A JSON preview
has "applied": false. The confirmed result has "applied": true.
Turning Wi-Fi on and turning airplane mode off do not require confirmation.
Brightness, volume and keyboard lighting accept whole numbers from 0 through
100. Mute, Wi-Fi, Bluetooth, airplane mode and Do Not Disturb accept on or
off. Caffeinate accepts on or off on local, where it holds a macOS power
assertion, and on a Linux target when the GNOME Caffeine extension is active.
Discovery and availability
status reports only controls the target can implement. For local, this Mac
is controlled natively without any extra tools: Core Audio for volume and mute,
CoreWLAN for Wi-Fi, the system Bluetooth, display and keyboard backlight
frameworks for those controls, and a power assertion for Caffeinate. The
Edith Machines engine holds that assertion, so the app and ed see the same
state, and it ends when Edith quits. No blueutil, brightness or
mac-brightnessctl install is needed. For remote targets, status checks Linux
tools such as brightnessctl, wpctl, nmcli, bluetoothctl, rfkill and
gsettings, plus the matching macOS facilities. Caffeinate supports both the
current cli-toggle and older toggle-state GNOME Caffeine keys. Windows uses
native CIM, Core Audio, network-adapter, Plug and Play, and notification settings
APIs. A missing control is null in JSON and omitted from the human table. If
the target reports no controls at all, the human command exits 4 with an
availability error.
Some Linux controls require a stored sudo password. Edith reads the same
Keychain entry used by the app and passes it on standard input to sudo -S.
The password is never placed in arguments or output. The sudo password applies
to remote targets only; local changes need no password or authorization
prompt.
JSON
Status returns one object with stable nullable fields:
{ "airplaneMode": false, "batteryLevel": 73, "batteryPluggedIn": true, "bluetoothEnabled": true, "brightness": 61, "caffeinateEnabled": true, "doNotDisturb": false, "keyboardBacklight": 18, "local": false, "machine": "box", "muted": false, "platform": "linux", "volume": 42, "wifiEnabled": true}Mutations return the machine, whether it is local, the stable operation ID, the requested value and whether the change was applied.
Exit codes
| Code | Meaning |
|---|---|
| 0 | Status was read, a change was applied, or a disruptive change was previewed. |
| 1 | The target rejected the change. |
| 2 | Arguments were missing or invalid, including a level outside 0 through 100. |
| 3 | The machine name was not found. |
| 4 | The machine could not be reached or did not expose the requested control. |
Where to go next
ed machinesfor machine setup and live metrics.- The
edcommand line for the complete reference.