procmail
[Top] [All Lists]

Re: probs with -ds and digest TOC

1997-02-16 13:38:34
Gary Funck continued,

| This particular 'digest' is actually a collection of individual
| articles, an old digest archive, with the extra MIME-Version field
| in the TOC, and some new digest articles without it.

| Which brings me to the real problem that I'm trying to solve: What I
| really want to do, is split this big file containing a mix of
| individual mail messages, and digest messages into individual
| messages.  So, I want to reserve the -+1ds option only for a message
| that appears to be a digest, or at a minimum will be parsed into two or
| more messages.  Any suggestions on how to approach this problem?

You could feed the file to formail -ds procmail .anrcfile and then have the
recipes in .anrcfile throw out digest envelopes and TOCs while safely filing
digest articles and individual messages that weren't in digests.

| One formail option that might be useful is to require either a 'From ' or
| a 'From: ' line as one of the fields that is counted.

There won't be a 'From ', but you can look for From:.  Then, as you said,

| I realize that I can
| accomplish such a check (and more!) by running the output through a
| procmail recipe, and may end up doing that.  Would a check for a
| required FROM field, break on commonly used mailbox or digest fomats?

It shouldn't.  Every valid article should have a From:.  It might break when
articles include quotes from earlier articles, headers included, with no
indentation.

<Prev in Thread] Current Thread [Next in Thread>