The Section Decoding Messages with mimecat gives an overview of this script. Here is the mimecat script (you might want to open it in a separate browser window). To install it, see the Section Programs in This Book's Archive.
mimecat writes certain MIME content-types to the standard output. You have to configure it to output the types that you want to be output. The file named by $profile contains an mhn profile; it writes the contents you choose to standard output. Contents not listed will use default rules in your MH profile or the system mhn_defaults file. Why? As explained in the Section Profiles that mhn Reads, mhn checks three profiles for an mhn-store- entry. If the profile in mimecat doesn't write the content to standard output, mhn will use an entry from another profile. Because those other entries probably won't write to standard output, as you want, you need to be sure that mimecat has entries in its $profile for all types you want to output. It's ugly, but it works.
mhn -store is verbose; it always tells you what it's doing. So mimecat grabs the standard error output from mhn -store. mimecat outputs any lines from mhn that don't seem to be about storing to standard output. That is, mimecat tries to delete informational messages but show errors. You may also need to tweak this part of the script, especially for versions of MH after 6.8.3.
[Table of Contents] [Index] [Previous: Explanation of mhprofile] [Next: Explanation of mysend]
This file is from the third edition of the book MH & xmh: Email for Users & Programmers, ISBN 1-56592-093-7, by Jerry Peek. Copyright © 1991, 1992, 1995 by O'Reilly & Associates, Inc. This file is freely-available; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation. For more information, see the file copying.htm.
Suggestions are welcome: Jerry Peek <firstname.lastname@example.org>