Alerts are user-specified commands that run when incoming mail arrives. The Alerts ... option invokes a specific command when incoming mail containing a certain string pattern in its header arrives. You can specify a different string pattern for each command you define. When mail arrives, the headers are scanned for a match with any of the patterns. When a match is detected the associated command is executed.
The alert command can be any executable program. You can
specify the program's full path name, or your
variable is used to find the program.
You can pass the message headers and/or the message body to
the alert command. If
%m is added to the command,
create a file with the entire message contents and replace
with the name of that file.
%h will be replaced with the name of
a file containing just the message headers.
%b will be replaced
with the name of a file containing just the message body.
be replaced with %. Here is an example command that will
From: headers in a new message using the
mfyi -center "`egrep `^(Subject:|From:)' %h`"
Possible uses for alert commands include:
To add or insert new alerts, and to edit or delete existing alerts, click the Alerts ... option. The Alerts dialog window appears.
The Alerts dialog window shows the list of current string patterns and associated commands in a box containing two text fields - the Pattern name field and the associated Command field. (If no alerts have been defined, both fields are empty). Each pattern must have a command associated with it.
Each pattern is evaluated as a regular expression, as defined by the UNIX ed command.
Enable Alerts button in the upper right corner of the
window lets you temporarily disable all alert commands without
having to delete them.
You use the four buttons to the left of the text fields to:
When you click the New ..., Insert ... or Edit ... buttons, the Edit Alert Rule window appears. It contains text fields in which you can create or modify an alert.
New alerts are added to the end of the list. Since patterns are evaluated in order, this means that the newest alert pattern is checked last. To create a new alert:
Since patterns are evaluated in order, inserting an alert ahead of other alerts causes its pattern to be evaluated first. To insert an alert:
To edit an alert:
To delete one or more alerts:
A pop-up confirmation box prompts you for confirmation before completing the operation.
Apply or cancel your changes using the row of buttons across the bottom of the window. See Applying Your Changes.