Event Triggers¶
Run triggers automatically based on system events.
Summary | |
---|---|
Available on macOS version | 10.11, 10.12, 10.13, 10.14, 10.15, 11.6, 12.4 |
for Quicksilver build | 4024, 4026, 4039 |
Event Triggers¶
With this plug-in, Quicksilver can run actions automatically as things happen on your system. For example:
- When the screen saver activates, pause iTunes.
- When the computer wakes from sleep, open Mail.
- When the network changes, run a shell script.
- When a disk named "Backup" is mounted, compress a specific folder and copy it to the disk.
- When switching to the internal speakers (headphones disconnected), pause iTunes.
(Some examples require other plug-ins.)
Quickstart¶
In order to create an example event trigger for experimentation:
- Open Quicksilver settings
- Install you have the
Event Triggers
plugin installed - Go to the
Triggers
preference pane - Use the
+
button (bottom left) and selectEvent
- In the pop-up interface, create the action you want to run
- For example,
Quicksilver is awesome!
⇥ Large Type
- For example,
- Find your action in the list of triggers, e.g.
Show "Quicksilver is awesome!" in large type
- Use
⌘``I
(or thei
icon bottom right) to open the sidebar - In the sidebar, choose an easy to trigger event such as
Switched to A/C Power
(assuming you're on a laptop) - Test it out: if on a laptop, unplug and replug your power cable and expect to see a text popup from Quicksilver appear automatically
Built-in Events¶
You can assign triggers for the following events:
- Application Launched
- Application Quit
- Quicksilver Launched
- Quicksilver Launched (at Login)
- Quicksilver Will Quit
- Active Space Changed
- Computer Will Shut Down
- Computer Will Sleep
- Computer Woke Up
- External Display Changed
- Fast Login
- Fast Logout
- Ethernet Changed
- Disk Mounted
- Disk Ejected
- Disk Will Eject
- Screen Saver Started
- Screen Saver Stopped
- Switched to A/C Power
- Switched to Battery Power
- Switched to UPS Power
- Switched to Headphones
- Switched to Internal Speakers
- Switched to S/PDIF
- Internet Became Available
- Internet Became Unavailable
Plug-in Events¶
Other plug-ins may define additional events. These are generally things that happen when running an action in Quicksilver, rather than on the system in general.
Events generated by Quicksilver should be marked with ☿
.
Trigger Settings¶
Event¶
Choose the event you want Quicksilver to watch for.
Delay¶
When the event happens, wait a certain number of seconds before running the trigger. It doesn't need to be a whole number. For instance, 0.1 and 2.5 are valid values.
Ignore Repeats¶
Match & Ignore Items¶
By default, an event trigger will run for every occurrence of the event.
For certain types of events, you can control whether or not the trigger runs depending on the object the event was related to. (See below for more on the Event Trigger Object.) For example, you might want to run a backup script when a particular disk is mounted, but not every time any disk is mounted. These restrictions can be set up by adding objects to the match/ignore lists.
Select objects in the main Quicksilver interface and drag them to either the Match Items or Ignore Items list. Multiple items can be added at once using the comma trick.
Event Trigger Object¶
This plug-in adds a proxy object called "Event Trigger Object" to the catalog. It's only useful within the context of an event trigger.
When an event happens, it can pass something along. You can then use an event trigger to run an action on that thing. For example, the iTunes plug-in defines an "iTunes Track Changed" event. When this happens, the Event Trigger Object will refer to the track that just started playing. So, for example, you could create a trigger like
Event Trigger Object ⇥ Add to Playlist… ⇥ Just Played
To see what the Event Trigger Object refers to for a particular event, check the documentation in the plug-in that defines the event. For events that don't explicitly provide an object, the Event Trigger Object will just be text containing the event's name.
Known Event Trigger Objects¶
For the events defined by this plug-in, the following objects will be available.
Event | Event Trigger Object |
---|---|
Application Launched | The application that launched |
Application Quit | The application that quit |
Disk Mounted | The disk that was mounted |
Disk Ejected | The disk that was ejected |
Disk Will Eject | The disk that will eject |
This plug-in uses icons from the Open Icon Library.