At 18:30 2004-11-01 -0600, Sean wrote:
I'm having a difficult time getting procmail to both deliver a message and
send a bounce back (autoresponder).
So far my only solution is to deliver everything local in .forward and
send to procmail.
"|IFS=' '&& exec /usr/bin/procmail -f-||exit 75 #autoreply"
This is not optimal.
I don't know if you normally have to use the .forward or not (if procmail
isn't set up as the LDA on your host, then you're stuck with invoking it
that way), but you should revert back to whatever you needed to just invoke
I've setup a new .procmailrc with the following:
The 'c'opy flag is notably absent (and only needs to be on the first recipe
here - if you put it on the second one, then you'd have an EXTRA copy in
your system mailbox as well). Thus, the recipe operates on the ONE copy of
the message, and when it's been piped to formail, it is considered to be
Additionally, there can be only ONE delivery line on a recipe, so lose the
Maildir delivery which immediatley follows the formail invocation.
That makes the procmailrc something like the following (with some
optimization - the header checks are "cheaper" than invoking an external
program, so if they exclude a message from processing, you save cycles):
* $ !^From:(_dot_)*$LOGNAME(_at_)domain\(_dot_)com
* $ !^X-Loop: $LOGNAME(_at_)$HOST
* $ ?/usr/bin/test -e $HOME/autoreply.txt
| ( formail -r -A"X-Loop: $LOGNAME(_at_)$HOST"; \
cat "$HOME/autoreply.txt" ) | $SENDMAIL -t -oi
Sean B. Straw / Professional Software Engineering
Procmail disclaimer: <http://www.professional.org/procmail/disclaimer.html>
Please DO NOT carbon me on list replies. I'll get my copy from the list.
procmail mailing list Procmail homepage: http://www.procmail.org/