Tuc wrote:
What I'd like to be able to have is something like (pseudocode) :
if exists (/home/$LOGNAME/.procmailrc)
then
INCLUDERC=/home/$LOGNAME/.procmailrc
You don't want to do that in /etc/procmailrc without dropping privileges
first.
exit
else
| /usr/local/cyrus/bin/procmail-cyrus-delivery.sh $LOGNAME
fi
Now wait ... is procmail-cyrus-delivery.sh a filter as the current code
you quoted indicates or is it a delivering program as you imply now?
I'm assuming the latter.
What I want is that if the user has his own procmailrc, then run it
and stop after its done. If not, then just go through the regular delivery.
Does "the regular delivery" mean handing the message over to
procmail-cyrus-delivery.sh?
Let's see ... I think this should be enough:
:0
* ! ? test -f $HOME/.procmailrc
| /usr/local/cyrus/bin/procmail-cyrus-delivery.sh $LOGNAME
and then if $HOME/.procmailrc does exist, procmail will have reached the
end of /etc/procmailrc, so it will drop privileges and move to
$HOME/.procmailrc on its own.
If there's no /bin/test and procmail needs to invoke a shell to run
test, add a semicolon to the end of the condition.
____________________________________________________________
procmail mailing list Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail