README for metamail integration with ifile.

TERMS
-----

These scripts were written by Jens Peter Secher <jpsecher@diku.dk> in
2002.  I hereby grant everyone an unconditional, irrevocable
royalty-free, non-exclusive, world-wide license to any copyright on
the work I may have in any jurisdiction; this license includes the
right to prepare, distribute and sublicense modified and/or derived
works without my prior specific permission.

CONTENTS
--------

README	This file.
mailcap	File that tells metamail what to do with attachments.

USE
---

Metamail is used for decoding multi-part emails (MIME).  The provided
file "mailcap" can be used to override the normal behaviour of
metamail such that all output is text.  To use the "mailcap" file,
pipe each message through the command

     KEYHEADS='*' MAILCAPS=mailcap metamail -d 2>&1

(assuming korn-like shell), which will output all headers and
printable parts of the email on stdout.  Unprintable parts are output
as a string

   encodedinlined<type>

where <type> is the MIME type, for example, "imagejpg".

Metamail can thus be used as a preprocessor for ifile, for instance by
the following script.
 
#!/bin/sh
KEYHEADS='*' MAILCAPS=/usr/share/doc/ifile/examples/metamail/mailcap metamail -d 2>&1 | \
ifile -v0 -q  | \
head -1 | \
cut -f 1 -d " "

END OF README.
