I am trying to create a don't-kill file. but can't get it to work.
What I want to do is send all mail which isn't sent explicitly to me,
*except* those which have the from address listed in a text file.
(I get all mail sent to my domain)
Based largely on a killfile routine found in the FAQ, this is what I have
#----Likely to be Spam!---
* ! ?grep -s `formail -x 'From '` notspam.txt
This seems to work fine and filters out 99% of the spam I receive, however
it also filters out mails from mailing-lists. even the ones which have the
"from" address listed in the file "notspam.txt"
The grep seems to work fine, if the mail is from a person in the notspam.txt
then the grep returns the name correctly and returns nothing if it isn't.
The problem seems to come from trying to invert the return from grep.
Has anyone got any ideas how to solve this please.
procmail mailing list