reformime [ options ... ]
reformime is a utility for reformatting MIME messages.
Generally, reformime expects to see an RFC 2045 compliant message on standard input, except in few cases such as the -m option.
If no options are given, reformime prints the MIME structure of the message. The output consists of so-called "MIME reference tags", one per line. For example:
1 1.1 1.2
This shows that the message contains two different MIME sections. The first line of the MIME structure output will always contain "1", which refers to the entire message. In this case it happens to be a multipart/mixed message. "1.1" refers to the first section of the multipart message, which happens to be a text/plain section. "1.2" refers to the second section of the message, which happens to be an application/octet-stream section.
If the message is not a MIME message, or it does not contain any attachments, reformime prints only "1", that refers to the entire message itself:
1
Here's the output from reformime when the first part of the message was itself a multipart/alternative section:
1 1.1 1.1.1 1.1.2 1.2
Arbitrarily complex MIME constructs are possible.