procmail
[Top] [All Lists]

help! procmail stops in the middle of my recipe

2002-07-02 11:24:16
Given the following recipe, if no value is found - which sometimes will
be the case - procmail does not continue reading the recipe and never
gets to the end where the program is triggered using the input values.

What syntax is necessary in order for procmail to continue reading
and processing even though it encounters no value for one or more
fields?


SHELL=/bin/sh
PATH=$HOME/bin:/usr/bin:/usr/ucb:/bin:/usr/local/bin:.
MAILDIR=$HOME/mail      # You'd better make sure it exists
DEFAULT=$MAILDIR/mbox
LOGFILE=$MAILDIR/log
LOG="
"
LOGABSTRACT=all
VERBOSE=yes

:0
* ^Subject: ref*
{
:0
  * ^Subject: *\/ref[^ ]+
  {
         REF=$MATCH

         :0B
         * ^Enter the domain name:\/.+[a-z0-9]
         {
                 NEWDOM=$MATCH

                 :0B
                 * ^First and last name of contact:\/.+[a-z0-9]
                 {
                         CONTACT=$MATCH

                         :0B
                         * ^E-mail address of contact:\/.+[a-z0-9]
                         {
                                 EMAIL=$MATCH

                             :0B
                         * ^Phone number of contact:\/.+[a-z0-9]
                         {
                                 PHONE=$MATCH

                             :0B
                         * ^Name of organization:\/.+[a-z0-9]
                         {
                                 ORG=$MATCH

                             :0B
                         * ^Optional 1st hostname [default www]:\/.+[a-z0-9]
                         {
                                 HOST=$MATCH

                             :0B
                         * ^IP address if provided:\/.+[a-z0-9]
                         {
                                 IPADDRESS=$MATCH

                 :0B
                 * ^CNAME if it applies [default www.ncgov.com]:\/.+[a-z0-9]
                 {
                         CNAME=$MATCH

                                 # your script probably doesn't actually
read
                                 # the STDIN, so 'i'gnore write errors.
                                 :0i
                                 | /usr/local/adm/build_domain $NEWDOM
$CONTACT
$EMAIL $PHONE $ORG $HOST $IPADDRESS $CNAME
                         }
                       }
                    }
                 }
              }
           }
        }
     }
  }
}


_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

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