procmail
[Top] [All Lists]

Re: Terminology (was Re: Nesting and braces)

1999-06-21 21:39:22
At 11:06 AM 6/17/99 +0300, era eriksson wrote:

What I failed to point out explicitly was that this is a symmetric
relation: For every action, there needs to be a "prelude". Every
prelude can have exactly one action (if you can call a set of braces
"exactly one action").

(What I'm getting at is that it's a fairly common newbie mistake to
try something like

   :0
   * condition
   action
   {
       more stuff which goes with this prelude
   }

which is always incorrect and will lead to a "skipped {" log entry.)

In the quickref <http://www.iki.fi/era/procmail/quickref.html> I have
tried to standardize the term "prelude line" for the "colon, number,
flags, lock" line. Perhaps the manuals should define some sort of
standard terminology for the parts of a recipe to make them easier to
talk about. Here's what I have in mind:

           [ prelude line   :0 flags :lock maybe
  xxxxxxx  [             [  * condition
           [ conditions  [  * condition
           [             [  * condition
             yyyy             action

Here "xxxxxxx" stands for what I have tentatively called "prelude"
above. What would be a suitable term? (I don't think "prelude" really
cuts it because you will end up being confused between "prelude line"
[if we keep that] and "prelude".)


How about "preaction" (or "pre-action")?

For every action, there is a preaction.  Sounds like something
Isaac Newton might have said  :-)

And of course, there will be an action after any preaction.


Probably there should also be something to cover both braces and
actual actions (i.e. yyyy can be action or braces, and action can be
file, forward, or pipeline).

Well, the man page currently calls '{' an action (specifically, it says
that the action line can start with one).

My trouble is remembering that setting a variable is *NOT* an action.
It seems like it "ought" to be.  :-)

Cheers,
Stan

<Prev in Thread] Current Thread [Next in Thread>