
Integrating Mapil into generic mailers
--------------------------------------

	The file Mailer-Integration in the root directory of the Mapil
distribution is meant to contain general information on how to get
Mapil to work with different mailers.  This file will just contain
documentation for the code in this directory, which at present is only
the mapil-mbox program.


mapil-mbox
----------

	mapil-mbox can be used to apply mapil to a single message in a
mailbox in Berkeley Mail format.  On most unix systems the maildrop
files in /usr/spool/mail are in this format, and many popular mailers
including Pine and Elm keep their messages in this format.

	mapil-mbox is meant for users who rarely get a PGP or P/MIME
message and but occasionally need to check one they do have and don't
mind some inconvenience.  mapil-mbox can be used with many different
mailers, but it is still inconvenient to check or decrypt messages,
and it provides no facility for producing PGP encrypted or signed
messages.

	Before I actually explain how to actually use this program, I
should give a STRONG WARNING.  I have tested this program a bit, but I
don't use it myself since my messages are in MH format.  This program
reads and writes an entire mailbox file.  I shudder at the thought of
a naive user running this code on a mailbox full of 300 important
messages.  In addition, the Berkeley mailbox format is undocumented,
and it seems many mailers may use slightly different standards.  For
that reason, mapil-mbox will not write to the given mbox file unless
it can rename it to mbox~.  That being said, I think this works, but
after you run it, check the messages before and after the mapiled
message, and if anything looks wrong, recover your mailbox from the
backup.  And of course, send me mail about it afterwards.

	Now for the actual instructions, which are simple:

mapil-mbox filename N [mapil options]

	will run mapil on the Nth message in the mailbox whose name is
filename.  It will rename filename to filename~.  The mbox file
filename will be unchanged, except the Nth message will be replaced by
the results of mapil processing it with the specified options.  mapil
must be in your path.

	For instance, if you have a folder in ~/mail/incoming whose
5th message is PGP encrypted, you could decrypt it by running:

mapil-mbox ~/mail/incoming 5

	If you wanted verbose output, you could run:

mapil-mbox ~/mapil/incoming 5 -v 9

	Either way, when you ran your mailer again, all the messages
in incoming would be the same except message 5 would no longer be
encrypted.


