NOTE: This page describes Version 2.5 of Script Timer. Version 1.2 of the program is very briefly discussed elsewhere.
Contents:
Figure 1: Main Document Window
Figure 2: Action Panel
Figure 3a: Preferences Panel (Files and Folders)
Figure 3b: Preferences Panel (Actions)
Figure 1: The Script Timer 2.5 Main Document Window
A document window contains two "panes". The upper pane lists the contents of the Designated Items to Schedule Folder, which is a convenient place to hold the items you schedule frequently. To schedule an item shown in this pane, simply drag and drop it onto a tabbed view in the bottom pane. You can also drag an icon from the Finder to schedule it. The appropriate Action Panel (see below) will come up, depending on which tabbed list of actions is frontmost.
Note that there are three types of actions:
• Time of Day Actions run at a specific time of the day, week, month, or year,
• Repeating Actions repeat on a time interval from one second to any number of weeks, and
• Event Driven Actions run when certain events occur such as when the computer enters or leaves an idle state, just before or just after the computer sleeps, or when you log into or out of your account.
Actions listed in a table can be sorted by columns by clicking on a column header. They can also be rearranged or copied to another document window or program by standard drag and drop techniques.
Script Timer can handle any number of action data files, and you can easily switch among them, including by scheduling an AppleScript script containing a custom command. This allows you to schedule different sets of actions at different times and automatically shift among them.
The lower pane is flanked on the right by six buttons:
• The Start button is used to turn the scheduling engine on and off. The scheduling engine is a faceless background process that does the actual scheduling and execution of the actions stored in a Script Timer data file.
• The New button provides an alternate way to the drag and drop method to create a new action to schedule.
• The Edit button brings up an Action Panel for the action or actions selected in an action table so that their properties can be edited. Alternately, you can just double click on an action to bring up the panel.
• The Remove button removes the selected actions from an action table. You can also just use the Delete key.
• The Clone button is used to duplicate a selected item in an action table. It brings up an Action Panel pre-filled with data from a selected action that you can edit to make a new action.
• The Do Now button causes the selected actions in an action table to be executed immediately. This is a convenient way to test the correctness of a script before scheduling it for some time when you are absent from your computer.
Top of Page
Figure 2: Example of an Action Panel
An Action Panel is used to fill in the information
required for the scheduling engine to schedule and run
actions. Action panels appear whenever you want to create a
new action or edit an existing one. Each of the three
action types has a slightly different panel, reflecting the
different characteristics of the action type. The panel in
Figure 2 is for a Time of Day action. It shows the
properties of an action that schedules the Track Timer iTunes controller script to
play an iTunes play list called "Jazz Faves" every
weekday at 6:00 PM.
The Parameters field allows you to pass parameters to
AppleScript, perl, or shell scripts, and file paths to
Automator workflows.
The Wait Time is the time in seconds that the scheduling
engine will wait for a script to run to completion. Waiting
allows the engine to receive data returned by the script
for further action. NOTE: The Wait Time is not honored for
an AppleScript script unless the script addresses another
application through a 'tell' command. The Script Timer
scheduling engine will wait indefinitely for an AppleScript
script without 'tell' commands to complete.
There are three types of data a
script can return (the latter two being specific to
AppleScript):
1. Information for inclusion in the Script Timer log file,
which you can view in the program at any time.
2. A New Action Record, which the scheduling engine uses to
schedule a new action on the fly. This "dynamic
scheduling" feature lets your AppleScript script
both construct and schedule another action for a different
time depending on its own outcome.
3. Information to indicate whether or not you want the
application that was front most on the screen before the
action started to return to the front when it ends. Not
restoring the front most application allows a script to
start another application and have that application remain
front most.
An action need not involve a script - it could launch an
application or in OS X 10.4 or later an Automator workflow,
or open a document. If the item is not a script or
workflow, the Wait Time is automatically set to zero and
disabled, as is the Parameters field.
The other action types, Repeating and Event Drive actions,
have Start and Stop times, allowing you to bracket the
hours you want an action to run. For example, you might
want an action to take place every hour between 9 AM and 5
PM. With Time of Day actions you can specify a "Late Start"
time. An action will run even if its normal Start Time has
passed when the scheduling engine starts up provided the
Late Start time has not passed.
Top of Page
Figure 3a: The Script
Timer Preferences Panel (Files and Folders)
The Files and Folders Preferences panel shows the two
main files and the folder associated with the program.
• Current Data
File: You can have many different data files,
but only this one will be used by the scheduling engine.
Changing the active data file is accomplished by
choosing the new data file here, by the "Set As Current
Data File" command in the File menu, or by scheduling an
AppleScript script that uses the custom "change data
file" command built into Script Timer.
• Designated Items to Schedule
Folder: This is a convenient place to hold
frequently scheduled items. You can change it here in the
Preferences panel, or by dragging a different folder onto
the upper pane of any Script Timer document window.
• Log File: Script Timer maintains a
log file that your scripts can also use to store their
results. This lets you write simpler, more task oriented
scripts.
This panel also allows you to control the behavior of the
scheduling engine and the status monitor.
You use the "Start at Login" checkbox to arrange for the
scheduling engine to automatically start when you log into
your account, what you would normally want to do.
The "Status Monitor Enabled" checkbox determines whether or
not the optional status monitor is active. If so it will
automatically start at login. The status monitor displays
the scheduling engine icon in the system status bar to the
right of the main menu bar. The icon is faded if the
scheduling engine is not running, allowing you to ascertain
its state at a glance. An attached menu allows you to open
Script Timer or turn the scheduling engine on or off.
The "Start or Stop Status Monitor" button allows you to
turn the status monitor on or off at will.
If the "If on line check for new program version on
Internet" option is selected, Script Timer will
automatically check for newer versions of itself on the
Apps & More web site when you launch it if the Internet
is reachable, and alert the user. (If you normally connect
to the Internet via dialup modem, the Internet is not
considered reachable unless you are actively connected.)
NOTE: No data is sent to the web site from the computer
running Script Timer. With the increasing level of spam
on the Internet and the consequent increase in email
filtering, it is becoming more difficult for software
vendors to communicate with their customers. The danger of
a mass mailout about the availability of a new version
being filtered away is high. This feature makes it easier
for the user to keep up to date with the latest version of
the program.
Notes:
The auto update feature causes a data file to be saved
whenever you make a change in its document window.
Otherwise the scheduling engine won't notice any changes
you make in the Current Data File's document window until
you actually save the file.
Verbose logging increases the amount of information the
scheduling engine records about its operations in the log
file.
The Factory button resets the preferences to those that
come with the program.
Top of Page
Figure 3b: The Script
Timer Preferences Panel (Actions)
You can assign default values to most of the properties
of a newly created action, including the action type. Some
properties are common to all actions, and some specific to
each action type.
The Wait Time is the number of seconds the Script Timer
scheduling engine will wait for a script to complete before
continuing on. Waiting allows a script to return data to the scheduling engine for
further action. (NOTE: The Wait Time only applies to
shell and perl scripts, AppleScript scripts that address
other applications with a 'tell' statement, and
Automator workflows.)
You can decide whether or not you want the application that
was frontmost before an action started to be restored to
the front on your screen after the action completes. You
can override this preference on a script by script basis.
If your computer is asleep, no programs are running. You
can choose to have any actions that were missed during
sleep to be carried out when the computer awakes or to be
discarded. For example, you would not want a script that
chimed the hour to run multiple times upon awakening.
The scheduling engine checks for new actions to execute
every "Checking Interval" seconds. The checking interval
can be a little as one second though you would probably
only use such a short time in special cases such as when
combining Script Timer, Track Timer, and iTunes to run
an Internet radio station.
Actions normally start on or near the start of a checking
interval. However, the program allows you to change this to
any number of seconds into the checking interval. For
example, if you had the checking interval set to one
minute, actions would start at the "top of the minute" for
a zero offset. The Scheduling Offset would allow you to
delay the start of actions to any number of seconds into
the minute.
The logout actions scheduled for your account will only run
when you log out if the "Enable Logout Actions for this
computer" checkbox is checked. Logout actions are enabled
on a computer-wide basis, so if this box is unchecked no
account's logout actions will run when that account logs
out. For this reason you need Administrator privileges for
the computer to change this setting.
Top of Page