I need to detect "Content-Transfer-Encoding: quoted-printable" field, and
it the field exists, replace the content of with my new content
Content-Transfer-Encoding: 8BIT
and if the field Content-Transfer-Encoding doesn't exist, don't add the
field ? How do I do it with formail ?
Read "procmailex". Here is an excerpt:
The following example preconverts all plain-text mail
arriving in certain encoded MIME formats into a more com-
pact 8-bit format which can be used and displayed more
easily by most programs. The mimencode(1) program is part
of Nathaniel Borenstein's metamail package.
:0
* ^Content-Type: *text/plain
{
:0 fbw
* ^Content-Transfer-Encoding: *quoted-printable
| mimencode -u -q
:0 Afhw
| formail -I "Content-Transfer-Encoding: 8bit"
:0 fbw
* ^Content-Transfer-Encoding: *base64
| mimencode -u -b
:0 Afhw
| formail -I "Content-Transfer-Encoding: 8bit"
}