I have a .procmailrc file that includes a file named .rc.phplist. Within .rc.phplist is the following set of recipes:
:0
* $RECIP ?? ^^phplist@$DOMAIN
{
# Has this message already been sent? If so, delete it.
:0h
* ^X-Mailing-List:
/dev/null
:0cw
phplist/queue/.
:0
|/usr/local/bin/php -f /home/myuser/scripts/sendlist.php >> /home/myuser/scripts/sendlist.log
}
This handles all messages addressed to phplist@mydomain.org. The sendlist.php script distributes the messages in the queue folder to members of a discussion mailing list. It checks to see if it is already running and exits if so. The script will stop running when all messages in the queue folder have been sent. This recipe will restart it when a new message comes in.
Later in the parent .procmailrc file is this recipe:
:0
* $RECIP ?? ^^phplist@$DOMAIN
{
:0
!myemail@anotherdomain.net
}
Now it's my understanding that the recipe in .rc.phplist should stop procmail from processing the message. And if the message is plain text, that's just what happens. What's weird is that an HTML message causes *all* the recipes to be executed, even the one in .procmailrc.
Why???