Harry Putnam wrote:
SPAM_SPOOL=${SPAM_SPOOL:-spam}
FROM_ADDR=`formail -rtzxTo:`
:0c
$SPAM_SPOOL/.
# Here is where the files are sent to the spam folder.
# The /. on the end of the line tells procmail to use MH-
# style mail files, which is one message, one file. You
# can get rid of that by removing the /. and then you
# should get a standard mbox.
Trying this recommendation seems to generate a different format that is
still in "one file per message but has the format:
"msg.IX02" "msg.JX02" etc. Still not in Unix message format
The problem now is that the name "spam" you give procmail as the
destination for the messages now is the one of an existing
directory (from your earlier attempts). Either remove/rename the
"spam" directory before you continue testing (so that procmail
can create a *file* with that name in the next run and store your
messages there in the desired format) or change the first line I
quoted to set SPAM_SPOOL to some other value that's not a
directory name.
Oh, and once you're delivering to a file, you should add a colon
to lock the file during delivery, otherwise you get in trouble as
soon as two messages arrive shortly after each other and the two
procmail processes write to the file at the same time:
:0 c:
$SPAM_SPOOL
/HW