procmail
[Top] [All Lists]

RE: MH Mail folders question

2002-06-19 08:31:01

Edward Wildgoose <Edward(_dot_)Wildgoose(_at_)FRMHedge(_dot_)com> wrote:
Also the manual suggests that I can deliver to MH folders simply by
putting a dot at the end of the folder name to deliver to, but Eberhard
and Philip say that I should shell out and use the nmh tools...

Well, actually, that one is a bit of personal preference...if you want the
messages put into an 'unseen' sequence, you need to use rcvstore, but if
you don't care about that, following the manual and doing "directory/." is
good enough.

OK, I understand, sorry, I assumed by implication that procmail had some 
problem with MH folders.  Thanks for sorting that out.

Also I am particularly interested in how the write is carried out, ie is
it a write to a temp file, then atomically linked into position, or is the
file opened for writing and contents piped in.  Obviously if it is the
latter then I also need to correlate my lock files with my reader app
(custom perl program, doesn't use nmh as far as I am aware)

The write of the file is no big problem, given that the open/creat is
atomic, a unique filename can be guaranteed and the writes after that don't
matter.  If you want the unseen sequence updated, though, the writes to the
.mh_sequences file do matter and you'll need to lock for that when calling
rcvstore.

Hmm, but perhaps procmail writes out the first half of the file, and then my 
perl app reads the file and assumes that is the whole mail?  Please excuse me 
if I have failed to understand unix open/creat calls...

The ordering that I am after is oldest to newest and no other, so presumably I 
am fine to keep using the procmail method?

Thanks all,

Ed W
_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

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