Power Manager can schedule an external shell script to run at specific times or on-demand. An external shell script is separate from your Power Manager event and is often an executable file containing a bash, perl, python or ruby script.
We recommend embedding your scripts with Power Manager events. Embedded scripts can not be accidentally moved or changed without realising they are part of a greater workflow. Events with embedded scripts can also be shared easily; the schedule file contains everything needed. See our recipe about creating an event with an embedded script.
Sometimes an external script is the only available option. Let's walk through how to create a Power Manager event that executes an existing shell script on your Mac.
Creating a Shell Script Event
- Launch Power Manager.app.
- Click Add… to create a new event.
- Select the Launch an application daily task.
- Choose your external shell script for Launch which application?.
- After choosing your script, an Environment popup menu appears. This indicates Power Manager recognises the chosen file is a script and can be executed.
- Continue to the When step.
- Adjust the time and date to perform your script.
- Continue to the Constraints step.
- Continue to the Why step.
- Name and describe your new event.
- Continue and then Add your Power Manager script event.
Your event is scheduled immediately and will perform at the time you selected in the When step.
Your event is also available on-demand, through the Power Manager status menu and via Power Manager Remote on your iOS device.