procmail
[Top] [All Lists]

Re: formail -D generates empty msg. when duplicate found?

1999-12-11 14:44:25
From: gary(_at_)Intrepid(_dot_)Com (Gary Funck)
I'd read "not output a duplicate message" as meaning "nothing
will be sent to the output".  Also, does a mail message with
only "From " line qualify as a valid mail message?

The problem with sending something through is that it will
confuse simple scripts like this:

   formail -D 10000 id.cache -s echo . < mbox | wc -l

which attempts to count the number of unique messages, but
will actually count all messages, due to the dummy 'From '
being passed through.

Are you sure your scheme must rely on counting messages?
Is anyone else doing this?  (I'd like to see the recipes.)
Whu not do something more mundane, if more useful, and count
bytes and delete after a certain limit?

What I myself am thinking of implementing is a backup
of all non-list mail that would then get cleaned out by a cron job
and find after so many days.  I do this now (have for years) with
my procmail logs and auto-ack respondent database (everybody gets
an auto-ack no more than weekly from each unique sending address,
unless they request verbose acks or no acks).  It would be simple
to add saving mail to files each day and then use find
to delete mail over, say, 7 days old.  I would also gzip the
mail.

-- 
    \     .-.     .-.     .-.     .-.     .-.     .-.     .-.     /
     \-d-/-m-\-a-/-n-\-(_at_)-/-n-\-e-/-t-\-c-/-o-\-m-/-.-\-c-/-o-\-m-/
      '-'     '-'     '-'     '-'     '-'     '-'     '-'     '-'