Command reference
Quick Toggles
Quick Toggles has no command group of its own. Every switch and action on its
page and Home card is an operation of the running extension, sent through
ed invoke with a JSON payload. Results are JSON on
stdout; a refused request prints a JSON error on stderr and exits non-zero.
ed invoke quickToggles listed invoke quickToggles set --json '{"item":"darkMode","on":true}'ed invoke quickToggles run --json '{"action":"ejectAll"}'ed invoke quickToggles trashed invoke quickToggles run --json '{"action":"emptyTrash","confirm":true}'ed invoke quickToggles layout --json '{"item":"lockScreen","surface":"card","visible":false}'ed invoke quickToggles restoreItems
| Item | Kind | What it does |
|---|---|---|
darkMode |
switch | Light or dark appearance for the whole Mac, through System Events |
hideDesktopIcons |
switch | Finder CreateDesktop; Finder restarts to apply it |
showHiddenFiles |
switch | Finder AppleShowAllFiles; Finder restarts to apply it |
bluetoothSleep |
switch | Turns Bluetooth off at sleep and back on at wake, only when Quick Toggles turned it off |
ejectAll |
action | Ejects every external disk and disk image; internal and system volumes are skipped |
emptyTrash |
action | Empties the Trash through Finder after confirmation |
lockScreen |
action | Locks the screen now |
sleepDisplays |
action | Puts every display to sleep now |
screenSaver |
action | Starts the macOS screen saver now |
Operations
listtakes{}and returnsitems, in the saved order. Each item hasitem,kind(toggleoraction),title,detail,on(switches only),available,reasonwhen unavailable,changedByQuickToggles,onPageandonCard.settakesitemandonfor a switch and returns that item's new state. Sending an action returns an error that says to userun.runtakesactionand, foremptyTrash,confirm. It returnsaction,doneandmessage.ejectAlladdsejectwithejected,refused(nameandreason, such as the app holding the disk) andskipped.emptyTrashaddstrash; without"confirm": trueit changes nothing and returnsneedsConfirmation: truewith the item count and size.trashtakes{}and returnsitems,knownBytesandunknownSizes.layoutchanges the order and where items show. Sendorder,hiddenOnPageorhiddenOnCardas lists of items, oritemwithmove(a signed offset) or withsurface(pageorcard) andvisible. It returnsorder,hiddenOnPageandhiddenOnCard.restoretakes{}and puts back every original value Quick Toggles changed, the same work it does when it is turned off or removed. It returnsrestored,failedandbluetoothRestored.
Quick Toggles records each switch's original value before its first change. Turning the extension off or removing it puts those values back and turns Bluetooth back on if Quick Toggles turned it off. If Edith quits while that is unfinished, the next launch finishes it.
Dark mode asks macOS once for permission to control System Events, and the Trash count and Empty Trash ask once for permission to control Finder.