Hi, Jonathan,
you need to put ^ after From: like this:
if ( /From: ^jnic...@orange.scurvy.net/ )
From: is not a value, but a field. Value is anything after : till /. ^
means, that the string needs to be at the beginning on field value. I think
in this case you don't need that ^ at all. I am already filtering mailing
lists and daily log summaries, very nice indeed.
Gatis
-----Original Message-----
From: Jonathan Nichols [mailto:jnic...@pbp.net]
Sent: Thursday, April 10, 2003 12:42 AM
To: cour...@lists.sourceforge.net
Subject: [maildropl] can't get it to filter
Hrm.. I created a mailfilter file, I think it's being read..
Logs show this:
Date: Wed Apr 9 21:38:57 2003
From: Jon Nichols <jnic...@orange.scurvy.net>
Subj: Test
File: /home/vmail/phoneboy.org/phoneboy/.maildir/
(1345)
Date: Wed Apr 9 21:39:09 2003
From: Jon Nichols <jnic...@orange.scurvy.net>
Subj: Test
File: /home/vmail/phoneboy.org/phoneboy/.maildir/
(1345)
the .mailfilter file I'm sing shows this:
garbage tmp # cat /home/vmail/.mailfilters/phoneboy\@phoneboy.org
MAIL=/home/vmail/phoneboy.org/phoneboy/.maildir
logfile "/tmp/mailfilter-log.txt"
if ( /^From: jnic...@orange.scurvy.net/ )
{
log "testing"
to "$MAIL/.Test"
}
I tried it without defining $MAIL. Same result. I tried to
"$MAIL/INBOX.Test" - same result.
No matter what, it just drops everything off in INBOX.
What am I doing wrong?
Thanks..