Dallman Ross wrote:
However, whenever he writes "there's no other way," something fires
off in my head
In or at?
and I have to find another way.
LOCKFILE = foo.bar
:0
* HB ?? ? cat >> foo
$DEFAULT
LOCKFILE
Lovely, but you missed something, Dallman: other procmail processes may
be writing to $DEFAULT without locking foo.bar. You still need a local
lockfile on the recipe.
And, oh yes, you're assuming that foo is an mbox.
Shall I mention the forks of cat and $SHELL? Well, you never said it
was a great way, just a way. If we're going that route anyway with
forks and shells, if both foo and $DEFAULT are mboxes, try this:
:0:
| tee -a foo >> $DEFAULT
Since all writes to foo will be locked by $DEFAULT$LOCKEXT, there's no
need for a separate lock on foo. Yes,
:0:$DEFAULT$LOCKEXT
| tee -a $DEFAULT >> foo
is equivalent.
BTW, if foo and $DEFAULT are both classic procmail directories on the
same partition,
:0
foo $DEFAULT
will write the message to a file and hard-link it into both directories.
I don't know what happens if they're on different partitions, or if
they're MH directories or maildirs, or if they're two different types of
directories.
____________________________________________________________
procmail mailing list Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail