Using MH from Other Languages

Programs that use MH commands don't have to be interpreted by the Bourne shell, of course. An MH command may be run by any language that will start a UNIX process and can:

In a lot of cases, the program will do its own processing of text output by MH commands. For instance, Perl is good at parsing the headers of email messages. So, instead of using MH format strings, a Perl script might use show -noshowproc or mhpath to read a message header into an array -- then use Perl regular expression operators to get the information you need.

When you're trying to decide whether to use MH features or the features of your language, how do you choose?