Browse the docs

A State starts or ends

Runs the macro when a named State, such as Deep work or On the road, turns on, turns off, or either.

State name turns on or off

Details #

A State is a name for a situation, built from conditions: "Deep work is Xcode in front, no Zoom running". Switchboard keeps each State current. This trigger runs the macro when the State is entered (turns on), left (turns off), or both.

States come from the library (the States item in the sidebar). A State that you forced on or off from the menu bar also triggers.

InputWhat it holds
stateThe State's name.
edgeentered or left.
sinceWhen the State last changed before this.

{{triggerValue}} is the State's name.

Parameters #

ParameterTypeRequiredValuesWhat it does
nametextYesRequired. The State's name, matched without regard to case.
edgeone ofentered left bothentered (default), left or both.

Every trigger also takes Limits: a cooldown, the first time each day, every nth time, twice within seconds, a chance, only while you are at the Mac, on one Mac, or in a State. See Limits on any trigger.

Examples #

Mute the music when Deep work starts
When
  1. “Deep work” starts
Do
  1. Music: pause
Open in Switchboard to try it

Gotchas #

  • Nothing runs for the State being already on when Switchboard starts.

  • A State's own hold (2 seconds unless you set it) applies before it turns on or off.

See also #

A condition becomes true, State is on, state(), Triggers that watch: becomes true, States, waiting runs