Search | Directories | Reference Tools
UW Home > Discover UW > IT Connect > Pine Information Center > FAQs 
| Search Pine Information Center

Attachments to Email Messages


7.1 How do I attach a file in Pine?

When composing a message, move your cursor to the "Attchmnt:" line. Using Pine's "To Files" key (^T), go to the files on your computer; select the one you would like to attach. The file must be on the computer running Pine. You also have the option of typing in the full path name at the "Attchmnt:" line.

7.2 Why does Pine encode text attachments?

Pine uses MIME's Base64 encoding for all attachments, including text, in order to assure that they are not modified in transit. The goal is make sure that sending file attachments in Pine is as dependable as using FTP.

Although it may seem like encoding is unnecessary for files that are plain text, certain email gateway, trasport, and delivery agents pose a threat to the integrity of even text files (much less binary files). For example, long lines may be wrapped, trailing spaces deleted, tabs turned into spaces, lines beginning with "From" modified, etc.

7.2.1 How can I send a text file without it being encoded?

This is easily done by using Pine's "file inclusion" key (^R). Instead of entering the file name on the Attchmnt: header line, move the cursor to the bottom of your message, and press "^R Read File", then enter the name of the text file. It will be included at the end of your message without any encoding (unless the file contains 8 bit or binary characters, in which case the entire message becomes subject to MIME encoding rules.)

7.2.2 Why does Pine use Base64 instead of UUencode?

Pine uses the Internet MIME (Multipurpose Internet Mail Extensions) standard for all attachments. MIME uses "Base64" encoding rather than uuencode, because uuencode uses characters that are transformed by some email gateways, and there are also several incompatible versions of uuencode. However, if needed, you can certainly uuencode a file outside of Pine, then use the Composer's "file inclusion" (^R) command to insert the uuencoded file into the message.


7.3 How do I convert a Sun Mailtool attachment to MIME format?

Keith Moore <> has written a Perl conversion script to convert Mailtool to MIME. The Perl script and C conversion are available in

and a description of the program can be found in

7.4 How do I decode an attachment in a message I received that is in BinHex or UUencoded format?

Save the attachment to a file and use a decoding program running on the operating system you are using and capable of handling the encoding format; for example:

Please note: Successfully decoding an attachment alone does not assure that you can use the resulting file(s) on your computer. For example, you may be able to decode a BinHex-encoded file on your MS Windows/DOS PC, but end up with a Macintosh application that you cannot run; or you may not have the application program needed to open a data file. Ask the sender of the message with the attachment what it is/how do handle it, if in doubt.

7.5 How can someone without Pine decipher an attachment to a message I send?

Pine uses the MIME Internet standard for attaching files to email messages. Any MIME-capable mailer should be able to "understand" Pine's attachments. If the recipient of your message with attachment does not have MIME-capable email software, they should be able to save the attachment to a file and then decode that. One freely-available program which can decipher a MIME attachment is munpack from Carnegie Mellon. It is available at:

Another one is UUDeview, available at:

7.6 How can I delete attachments?

In Pine, message attachments can be deleted without removing the entire message. This is accomplished by marking the undesired attachment for deletion and saving the message to a folder. Attachments marked for deletion are excluded from the message when it is saved. In addition, the delete mark only applies for the current Pine Session, and is of course gone when the message is saved, and the attachment excluded.

The associated attachments of a message are viewed by pressing ">" or V, opening the ATTACHMENT INDEX. The undesired attachments can be marked for deletion by pressing D. To exit out of the ATTACHMENT INDEX press "<". To actually remove the attachment the message must be saved. Pressing S in the MESSAGE INDEX will display the following warning message:

Saved copy will NOT include entire message!  Continue?
Y [Yes]
N No

If you are sure you want to save the message and exclude the marked attachments, press Y for yes.


7.7 Why doesn't "attached-to-ansi" printing work?

So-called "attached-to-ansi" printing relies on the communication software you are using to interpret certain special character sequences that tell it to divert the incoming stream of characters to your printer, and then back to your screen. Perhaps 99% of "pine printing problems" are either due to PC or Mac communications software that doesn't understand ANSI escape sequences for printing, or (in the dialin case) software flow-control problems.

We didn't understand how big a problem software flow control was until 3.90 came out... we changed pine to intercept flow control characters so that users would not see Pine "wedge" mysteriously if a mis-type or noise generated a Control-S, but that did bad things when printers, modems, or comm software was depending on s/w flow control.

In 3.91 we added the preserve-start-stop-characters feature, so that Pine could be configured to respect s/w flow control characters (if the operating system did) for those folks who needed them. Enabling this feature should make Pine 3.91 behave the same way as earlier versions.

Then we discovered that some operating systems don't enable software flow control by default. So starting in 3.92, the preserve-start-stop-characters feature does more than "not ignoring" them, it will try to force the OS to pay attention to them.

So here's the sequence of things to try if you have pine printing problems:

  1. Check For Software Flow-Control Problems
    1. Try enabling preserve-start-stop-characters (requires 3.91 or later)
    2. If that doesn't help, verify that the OS is enabling s/w flow control; if it isn't, you can either change that in a global .login script, or as a worst case, wrap pine in a script that does it. By the way, on our AIX systems, we had to execute "stty -ixon" followed by "stty ixon" --no one here knows why the first stty is needed. (Note that explicitly enabling s/w flow control in the OS will not be needed in 3.92 or later).
    3. If neither of the above apply, double-check that you actually have some kind of flow control enabled on your system, either hardware or software.
  2. Check Your Comm Software For Ansi Printing Capability
    1. After ruling out s/w flow control problems, if printing still doesn't work, the odds are that the PC or Mac comm s/w is at fault. I don't know how to determine this other than via trial-and-error and word-of-mouth.
    2. The "ansiprt" utility included in the pine distribution can also be used for testing. It simply sends the specified text file to user's terminal device, bracketed with the ANSI escape sequences for print diversion. This is just what Pine does as well (although some versions of ansiprt offer a few options not available via Pine.)
  3. Possible Other Printing Problems
    1. Printing via Pine's "attached-to-ansi" facility to a postscript-only printer. Pine does not yet have the ability to encapsulate text into postscript, ala "enscript", so the custom print option using enscript and ansiprt will be needed in that case.
    2. Other printer-specific configuration problems. For example, whether or not the printer needs a trailing formfeed to eject the last page, or a control-D, or non-Unix newline conventions, etc. Many of these problem will also require using the custom print command option and "ansiprt".

| Search Pine Information Center