<<< Date Index >>>     <<< Thread Index >>>

Re: mbox script



On Wed, Jan 28, 2004 at 06:00:23PM +0100 I heard the voice of
Christoph Berg, and lo! it spake thus:
> 
> The mbox format is really simple: each mail starts with "From " at the
> beginning of a line (this means that you have to quote (like here) each
> From that occurs there.)

The difficulty is that it isn't always that easy; for instance, mbox's
that use the Content-Length: headers in the email will often not
escape From_'s in the messages.  I went through several iterations of
some rather ugly mbox parsing code before I eventually got something
that seems to work reliably.


> Or just use Mutt and press 'd' ;-)

That, or something like it [using an existing program that already
groks mbox] is probably the easiest.  Sure, mutt isn't really
_DESIGNED_ to be a non-interactive app, but pushing commands into it
on the command line can do some impressive things.  8-}


-- 
Matthew Fuller     (MF4839)   |  fullermd@xxxxxxxxxxxxxxx
Systems/Network Administrator |  http://www.over-yonder.net/~fullermd/

"The only reason I'm burning my candle at both ends, is because I
      haven't figured out how to light the middle yet"