For some reason though, when I do this, all mail goes to the
./Maildir/.SPAM/ maildir.
Am I calling it right from my .qmail file?
|maildrop mailfilter
And am I right in assuming that I don't need all the other maildrop
config files if I pass my mailfilter on the commandline to maildrop?
Charlie
-----Original Message-----
From: Charlie Watts [mailto:cewa...@frontier.net]
Sent: Sunday, March 17, 2002 7:59 PM
To: Charles J. Boening
Cc: cour...@lists.sourceforge.net
Subject: Re: [maildropl] if/else problems
On Sun, 17 Mar 2002, Charles J. Boening wrote:
<snip>
if ( /^X-Spam-Flag: YES/ )
{
to "./Maildir/.SPAM/"
}
else
{
to "./Maildir/"
}
That generates the following error (message never delivered):
delivery 5416: success: mailfilter(13):_Syntax_error./did_0+0+1/
I've had weird troubles, but not investigated, with maildrop liking
different syntax in different places.
I'm not sure if this will help -
Here's an abbreviated version of my /etc/maildroprc. I use the
"exception" clauses so maildrop will continue if the xfilter or deliver
commands fail.
# REFORMAIL is a utility that comes with Maildrop.
REFORMAIL="/usr/local/bin/reformail"
# Only scan stuff under 256KB
# If the spamd daemon dies, just deliver it ... (that's what 'exception'
does) # I figure that spamc has 256K limiting too ... but maildrop
already knows the message # size, and this way we can sometimes avoid a
fork ...
if ( $SIZE < 262144 )
{
# Stick the final recipient into the headers
# Strange maildrop syntax: Sometimes it wants the braces like
this,
# sometimes on the next line.
exception {
xfilter "$REFORMAIL -i'Delivered-To: $LOGNAME'"
}
exception {
xfilter "/usr/bin/spamc -f -d backup.frontier.net"
}
if ( /^X-Spam-Flag: YES$/ )
{
# If the "Spam" folder exists, save tagged mail there.
Otherwise bail.
exception {
to "./.Spam/."
}
}
}