On June 1, 2005 at 13:12, East Coast Coder wrote: > I need mhonarc to do two things: > 1) Parse the mbox format > 2) Convert all of the content types into HTML > > What I don't want is for mhonarc to save the results of #2 into a > file. I'd rather it hand it off to me (which it does, via the > callback), and let me handle saving it myself - I'm working on > nonstandard uses of it, as opposed to generating a collection of html > files.
Try passing the -noarchive option to mhonarc. I forgot about it, but I added it in a long time ago. Basically, it should go through the motions of processing a mailbox, but will keep any files from getting written. Exception: Attachments will get written. I am not sure if you are dealing with attachments. I recommend utilizing the ATTACHMENTDIR and ATTACHMENTURL resources. This way you can have all attachments placed in a single location. The ATTACHMENTURL is important for the converted message bodies so the links to attachments will work. > > You can suppress the creation of message pages by passing > > the -nomsgpgs option to process_input(). Note, if you do use > > -nomsgpgs, then the message bodies are completely skipped, bypassing > > any callbacks related to message bodies. > > > > This won't work for me - see above. So I guess I'll need to modify > the source a little bit. Any suggestions on the least invasive way to > do this? I'm looking into it. The -noarchive may be all you need, but I can see reasons why someone may want to exclude messages after the body is processed (e.g. a spam/virus check). I've already made edits to my working copy to allow CB{Raw}MessageBodyRead to return a false value to exclude a message from further processing. However, I need to check if code is needed to reverse some of the side-effects in read_mail_head(). > Okay - I assume that not having a db won't cause a crash anywhere (of > course, the features that require it won't work). One thing you need to do is do the "already-processed" check. I.e. If you rescan a mailbox for new messages, you will need to make sure you do not reprocess messages already archived. You should easily be able to do this in CBMessageHeadRead. --ewh --------------------------------------------------------------------- To sign-off this list, send email to [EMAIL PROTECTED] with the message text UNSUBSCRIBE MHONARC-DEV