Using the Pine Mail Program

Table of Contents

The Official Pine Information Center

UMBC Email Information

Introduction.

Pine is one of a number of mail agents available under Unix. A mail agent is the technical term that refers to a program that you can use to send or read electronic mail. Other mail agents available on the Unix systems at UMBC include: Elm, mail, emacs, and Xmailtool. The remainder of this document will be focused on using Pine under Unix, at the end we will describe some minor changes found when using the DOS version.

Pine was developed at the University of Washington as a follow on product to the Elm mail system. The goals set forth in the development of Pine were:

  1. to develop a mail agent that beginning users would find easy to learn,
  2. that did not require knowledge of other Unix utilities (such as the emacs editor) to use, and
  3. could run unchanged under both DOS and Unix.

To accomplish the first goal, Pine uses a menu based interface. Pine always presents all possible choices to the users based on where on where you are in Pine. Each menu choice is prefixed with a single letter, pressing that letter invokes that menu item. The primary menu in Pine is called the "MAIN MENU". This menu is displayed when you invoke pine, from this menu you can send mail, read mail, or configure Pine to your personal preferences.

Getting Started with Pine.

Before using Pine, you must log on to your Unix account. If you are unsure how to log into Unix a description is found in the ACS publication "Using Unix at UMBC." In addition, student consultants are available in ECS 005 to answer questions you may have. Once logged into the Unix system, to invoke Pine enter the command "pine" and press return. Remember that Unix is case sensitive and word "pine" should be lower case. Upon doing this the a menu similar to figure 1 will appear.

                   Figure 1. The Pine Main Menu
_______________________________________________________________________________
        PINE 3.05        MAIN MENU        Folder:inbox  17 Messages            



      ?   HELP        - Get help using Pine

      C   COMPOSE     - Compose and send a message

      I   MAIL INDEX  - Read mail in current folder

      F   FOLDERS     - Open a different mail folder

      A   ADDRESSES   - Update your address book

      O   OTHER       - Use other functions

      Q   QUIT        - Exit the Pine mail program




                    [Folder "inbox" opened with 17 messages]
? Help       Q Quit       F Folders     O Other
C Compose    I Mail Index A Addresses
_______________________________________________________________________________
The top line of the menu describes the version of Pine being used, in this case version 3.05; the particular Pine menu you are in; the name of the mail folder you are using; and the number of messages to be read. This line will appear in all of the Pine menus, the only item that will change is the name of the menu. If you ever get confused within Pine, refer to this line to find which menu you are using. Following the top line is a list of menu choices available, each choice is prefixed with a single character which when typed invokes that choice. For example, pressing the question mark character on the keyboard causes pine to display the help menus. The bottom of the screen gives a simple summary of the commands available. Finally, pine is not case sensitive when referring to the menu choices and will accept both the lower and upper case character.

The Pine Help Menu

As noted above pressing the question mark character "?" will invoke the help menu. Help in Pine is context based, meaning you will receive different help screens based on what menu you were in when you requested help. When in the main menu the help menu is a 25 page Pine User's Guide describing different features of Pine. Many of the features described are more advanced features of Pine that will only confuse the first-time user. However, as with all Pine menus the help menu will list the choices available to the user at the bottom of the screen. In this case the following appears

M Main Menu  E Exit Help                - Prev Page
                          L Print   SPACE Next Page                 W Where is
Out of context on the screen, this seems confusing. On the screen the choices M, E, -, L, W, and SPACE are highlighted in reverse video. Selecting "M" takes you out of the help menu and back to the main menu. Selecting "E" takes you of help and returns you back to the menu you were at when you selected help (in our case that was the main menu, however help is available from any menu. The word "SPACE" refers to the space bar, pressing the space bar displays the next page of the help text, likewise pressing the minus key "-" displays the previous page. Pressing the character "L" causes Pine to print out the help text on your default printer. If you would like to get more information than this document provides on using pine that is the best

method.

The Pine Compose Menu

Pressing the letter "C" will invoke the compose message menu. This menu is used for sending electronic mail to other users (possibly including yourself). Once the compose menu is selected Pine brings up a new menu named "Compose Message." The menu you receive is found below in Figure 2.

               Figure 2. The Pine Compose Message Menu
_______________________________________________________________________________
      PINE 3.05      COMPOSE MESSAGE      Folder:inbox  17 Messages            

To      : 
Cc      : 
Attchmnt: 
Subject : 
----- Message Text -----


Jack Suess                           UMBC Academic Computing
Internet: Jack@umbc.edu              Standard Disclaimer:
Bitnet: Jack@umbc                    The opinions expressed above are mine and
ATT: 410.455.2582                    not my employers.




^G Get Help ^C Cancel   ^R Rich Hdr             ^K Del Line ^O Postpone 
^X Send     ^D Del Char ^J Attach               ^U UnDel Lin^T To AddrBk
______________________________________________________________________________

The compose message menu is really divided into two distinct parts. The top four lines, above the line "----- Message Text -----", are referred to as the message header. Below that line you are in what is referred to as the "Message Text" portion of the message. The menu options displayed at the bottom of the screen are dependent on whether you are above or below the "----- Message Text -----" line. Above the line you have the options shown above, below the line you have a different set of options described below. At any time within the compose message menu you can move back and forth between the message header and message text areas. In fact, often when writing the message you will decide it useful to add another recipient to the mail message. if so, you can use the arrow (or sometimes called cursor) keys to position the cursor back to the "To" or "Cc" prompt and add the new user.

The message header lines define whom to send the mail too as well the subject line and file attachments to include. The "To" prompt is where you list the recipients of your mail message. The "Cc" prompt is where you specify a carbon-copy of the message to be sent to related parties. The "attachment" prompt is where you may specify files to be sent as attachments to the recipients, this will be described in more detail later in the document. Finally, the subject line is where you give a brief description of the topic of the message.

With many messages you don't care to "Cc" others or add file attachments, to bypass these lines you may either press the return key or use the arrow key to move to the next line. Once you have entered a subject line and pressed return the cursor moves below the line "----- Message Text -----" and you have entered the mail message editor which will be described in the next section.

When in the message header (the lines above "----- Message Text -----") a number of options appear. You will notice that some of the options appear as two characters, for example "^G" for get help. The "^" refers to the control key. On some keyboards this key is labeled "Control", on others it is labeled "Ctrl". In either case "^G" implies you press down the control key, keep it depressed and then press the key that follows, in this case "G". The control key is functioning like the shift key, meaning by itself it does nothing, only when pressed in conjunction with another character does it have an affect.

While many sub-menus inside the compose menu are beyond the scope of this document a few are important. Below is a summary:

The Pine Message Editor for Composing Messages.

We mentioned above that the Compose menu has two parts a message header which we described above and the message text field which we describe now. The message editor within Pine is named Pico because it is as small an editor as possible and still be useful. Pico only contains the most basic commands needed in composing mail. It's strength comes from it's simplicity. The majority of commands available in Pico are listed at the bottom of the screen. Below is the bottom menu displayed once inside the message text area.

^G Get Help ^C Cancel   ^R Read File ^Y Prev Pg  ^K Del Line  ^O Postpone 
^X Send     ^J Justify  ^_ Alt Edit  ^V Next Pg  ^U UnDel Lin ^T To Spell 
As discussed above, all commands starting with "^" refer to using the control key, thus "^G" means hold down the control key and press the letter "G". The Pine editor Pico can be used outside of Pine for any text editing work you need to do. To invoke the Pico editor at the Unix prompt enter the command "pico filename", where filename is the name of the file you wish to edit.

Pico supports the arrow or cursor keys for moving in the file. Thus you can use the up, down, left, and right arrows. Below is a summary of the pico commands:

To move a block of lines from one location to another enter ^K (delete line) command for each line you wish to move, then position the cursor at the line you wish to add the text. Then enter ^U to undelete the lines, ^U will save all lines in a paste buffer if ^K is entered repeatedly.

Reading Your Mail, the Mail Index Menu.

The Mail Index menu lists the messages waiting to be read. By default the messages are listed in Chronological order, oldest to most recent. This order is configurable within Pine, for example messages may be sorted in reverse chronological order, by subject, by size, or by username.

Figure 3, shown below, is representative of the Mail Index menu.

                 Figure 3. The Mail Index Menu
______________________________________________________________________________

       PINE 3.05       MAIL INDEX       Folder:inbox  Message 1 of 4

  N 1   Sep 10 basam@engr.umbc.ed  (6,182)
  N 2   Sep 10 basam@engr.umbc.ed  (4,075)
  N 3   Sep 10 basam@engr.umbc.ed  (2,069)
  N 4   Sep 10 basam@engr.umbc.ed  (2,972)






? Help       M Main Menu  P Prev Msg     - Prev Page  F Forward     D Delete
O OTHER CMDS V View Mail  N Next Msg SPACE Next Page  R Reply       S Save
______________________________________________________________________________
Messages flagged with a "N" on the left hand side signify new messages that have not been read yet. Messages where the left side of the message number is blank represent messages that have been read before but are awaiting some action. Pine will leave messages in your Inbox until you explicitly tell Pine to do something with that message. Your choices are too delete or save the message. Leaving messages in your Mail Index is a useful way of keeping a "todo" list.

Upon entering the Mail Index Menu the default action is to view the first unread message. Pressing the return key causes Pine to read the first unread message. Pine will display one screen at a time of the message, pressing the space bar instructs pine to display the next screen. If you wish to read a specific message in your Mail Index you may either use the up and down arrow keys or press "N" for next message and "P" for previous message. As you move within the Mail Index the message you have selected is highlighted.

Once you have selected the message there are a number of things you may do with the message. These are summarized below:

When saving messages Pine will prompt you for a folder name. This name can be any valid Unix file name, ideally it should be something that logically describes the content of the messages. Pine saves all folders inside a subdirectory of your account named "Mail". These messages are organized as mail folders so that you can use Pine to easily go back and access the message. This will be described in later.

When replying or forwarding mail to another user Pine will prompt you regarding whether to include the original message in the reply. Pine uses the standard Compose Message menu we described previously when replying or forwarding mail.

The Pine Folder Maintenance Menu.

In the previous section we briefly discussed mail folders. Mail folders allow you to organize electronic mail you have received in a logical fashion for future reference. From the Main Menu, selecting "F" involves the Folder Maintenance menu. Figure 4. is an example of the display that a beginning user might have.

                 Figure 4. The Folder Maintenance Menu
______________________________________________________________________________

inbox     sent-mail           saved-messages      accounts  acounts
addresses           afs       ansys     apple     asa       bio       bsd



? Help       M Main Menu  G Go to Fldr  - Prev Page   A Add         D Delete
O Open                    L Print   SPACE Next Page   R Rename      W Where is
______________________________________________________________________________
Generally folders are displayed alphabetically; however there are three exceptions to this. The inbox folder is where new mail is saved, selecting this folder is the same as selecting the Mail Index option from the main menu. The other two folders "sent-mail" and "saved-messages" are automatically created by Pine on your behalf. Pine records a copy of every outgoing message in the folder "sent-mail", in essence you are automatically carbon-copying yourself on outgoing mail. The folder "saved-messages" is the default folder to save mail in when you select the Save Message option from within the Mail Index menu (described in the previous section).

To select a folder to read use the arrow keys to select the folder. The left arrow moves you a folder to the left, right moves to the right, up and down arrow keys move up and down. As you select a folder it will be highlighted, press return when you have the folder you would like to select.

Once a folder has been selected Pine automatically invokes the Mail Index Menu is invoked using that folder. All commands available in the Mail Index Menu are now available. You can print, delete, reply, or forward messages.

The Other Menu. Configuring where to Print.

Selecting "O", for Other Menu, from the Main Menu brings up a display as shown in Figure 5.
             Figure 5. The Other Menu
_____________________________________________________________________________
         PINE 3.05         OTHER         Folder:inbox  8 Messages

   ?   HELP       - Information on your options at this point

   N   NEWS       - News about Pine changes

   K   LOCK       - Lock this keyboard against others using it

   M   MAIN MENU  - Go back to the main menu

   P   PASSWORD   - Change the password you use to login

   L   PRINTER    - Choose printer or print command
                    Current printer:lpr -Pacsnps

   D   DISK       - Show space used by mail folders and free space

? Help       K Lock Kbd   P Password    D Disk
N News       M Main Menu  L Printer

_____________________________________________________________________________
The most common use of this menu is to set the printer to use when the print command is executed inside Pine. Selecting "L", the Printer Menu, gives you three choices. These are listed below.

  1. 1. Printer attached to IBM PC or compatible, MacIntosh This may not work with all attached printers, and will depend on the terminal emulation/communications software in use. It is known to work with Versaterm Pro on Macs, and WRQ Reflections on PC's and with the latest UW version of NCSA telnet for either, and probably Kermit too.
  2. 2. Standard UNIX print command Using this option may require setting your "PRINTER" environment variable using the standard UNIX utilities. Command: lpr
  3. 3. Personally selected print command The text to be printed will be piped into the command given here. Some examples are: "prt", "lpr", or "enscript". The command may be given with options, for example "enscript -2 -r" or "lpr -Plpacc170". The commands and options on your system may be different these examples. Command: lpr -Pacsnps Selecting option 1 will allow mail you to print mail to a printer attached to your PC or Macintosh. As stated above, this option is dependent on the software package you use and may not work for everyone. Selecting option 2 is useful if you have previously defined a default printer for Unix printing via the PRINTER environment variable. Option 3, allows you to customize where mail is printed. At UMBC the general use laser printers are named ACSPS. Thus selecting option 3 and entering the print command of "lpr -Pacsps" will cause Pine to print all messages on the laser printers in ECS 019.

    The Address Book.

    Since email addresses are often long and in many cases difficult to remember Pine provides an easy to use address book. The address book is selected by entering the letter "A" at the Main Menu. There are two types of addresses, individual and list. A list is where you define a group of email addresses to be a single name. An individual address can refer to only one email address.

    Creating a signature file.

    Pine automatically includes a file named .signature into your message text. Generally, this file should be no more than four lines and contain how to reach you. Below is a sample one that I use.

    Jack Suess                           UMBC Academic Computing
    Internet: Jack@umbc.edu              Standard Disclaimer:
    Bitnet: Jack@umbc                    The opinions expressed above are mine and
    ATT: 410.455.2582                    not my employers.
    
    Create the .signature file in your default directory using the pico editor by entering the Unix command "pico .signature". If you want to change the name of the file used for your signature file edit the file .pinerc and look for the lines:
    # Name of file to read signature out of for inclusion in outgoing mail
    signature-file=
    
    Place the name of the file you wish to use after the equal sign.

    By default pine places the signature at the beginning of replies and forwarded messages. If you do not want this behavior edit the .pinerc file and look for the line #feature-list=signature-at-bottom,. Delete the pound-sign character at the beginning of the line and save the file. Your signature on replies and forwards will be at the bottom.

    Electronic Mail Addresses.

    A note on email addressing here at UMBC. Faculty who have unix accounts receive mail using username@umbc.edu. Occasionally, you will find that you need to communicate with people are at other institutions. For internet mail addresses all you need to do is specify the full email address of the recipient. For example, a ficticous user John Smith at UMCP might have the address "smith@umail.umd.edu" entering that email address would send mail to the user. Occasionally, you will encounter a colleague with a Bitnet email address. Bitnet addresses take the form username@nodename, using our example above John Smith might have a bitnet address of "jsmith@umdd". To send mail from Unix to that bitnet address you would need to specify the address as "jsmith@umdd.bitnet" . The ".bitnet" suffix is needed to inform the unix system that this message is not an internet message and should be routed to the bitnet network. For more information on email addressing consult the ACS publication "Using Unix at UMBC."

    Finding the Email Address of Someone.

    Finding an email address of a person on the internet can be difficult. We provide a tool for people to look up email addresses of people here at UMBC, this tool is named "ph". The ph command is a Unix command and must be invoked outside of Pine. We in ACS will be providing a separate document describing the features of ph in the near future, for now a simple example will illustrate one of it's many uses. Suppose I had a friend named linda brown. I know linda is a physics major but I don't know her account name. I could enter the command ph 'l* brown' (the single quotes are needed when the asterik is present) This would produce the output

    umbc7> ph 'l* brown'
    ----------------------------------------
                name: Ms. Laura L. Brown
            email to: laura@umbc.edu (laura@research.umbc.edu)
    ----------------------------------------
                name: brown linda
          curriculum: ba phys
            email to: lbrown3@umbc.edu (lbrown3@gl.umbc.edu)
    ----------------------------------------
                name: brown lance
          curriculum: ba othr
            email to: lbrown4@umbc.edu (no account registered)
    ----------------------------------------
                name: Ms. Linda I. Brown
            email to: librown@umbc.edu (librown@umbc2.umbc.edu)
    ----------------------------------------
    
    I could then see there is a Linda Brown, majoring in physics, with an email address of lbrown3@gl.umbc.edu. I could then send her a mail message since I now know her address.

    At UMBC, we have written a utility to use the www for you to use to look up people within the University of Maryland system. There is also a generic utility that provides access to any College or University using the ph server.

    Using Attachments in Pine

    Pine supports a standard known as MIME. MIME allows file attachments to be sent through mail. These file attachments can be files with binary character data, such as Word Perfect files, programs, data files, or Graphics output. The easiest method of sending a file attachment is to include the name of the file on the Attachment prompt when Composing a message. You may include as many files as wish, each will be sent as a separate attachment.

    When you reading a mail message inside the Mail Index menu you may enter the command "A" to handle an attachment sent to you. Pine will ask which attachment you wish to view or save. Enter the number of the attachment and press return. Then you will be prompted whether to view or save the attachment. In general, you will not be able to view attachments and should just select save. Then you will be prompted for the name of the file to save this under.

    Accessing Usenet News Through Pine

    How to Post a Message?

    It is very easy to send a message to a newsgroup with pine. Here are the steps to do this:

    1. Enter the "Compose Message" "C" command within pine. Once you type "C" you will get the familiar e-mail message header with the "To:" prompt at the top.
    2. To send the message to a newgroup use the ^R command to turn on Rich Headers (remember ^R signifies hold the control key and press the letter R). When you do that you will see three additional message heading lines appear. One of these is named Newsgrps:
    3. Enter the name of the newsgroup you wish to send mail too (e.g. umbc.course.XXXXXX)
    4. Compose the message as you would any message.

    How to Read a Message With Pine

    Here are the steps to do this.

    1. Select "L View Folders or Newsgroups" in the main menu.
    2. Press the down arrow key so that the Newsgroup collection is highlighted.
    3. If you have not subscribed to this newsgroup you should do so. To do this enter the command "A" for Subscribe. Then enter the name of the newsgroup you wish to subscribe too and press enter.
    4. The newsgroup will be highlighted on your screen, press the enter to view the messages in the newsgroup.

    Forwarding Mail to Another Account.

    Often faculty and students have many Unix accounts. It is wise to have all mail forwarded to one account where you read mail instead of trying to sign on and manage multiple email accounts. This is easily done on Unix by creating a file in your account named ".forward". To forward your mail from one location to another, sign onto the machines you want mail forwarded from and create a file named ".forward". The ".forward" file should have one line which is the email address to forward your mail to. A valid forward file would contain one line and look like "jack@umbc.edu". Under VMS you enter the mail utility via the command "$mail". Then enter the command "set forward username@umbc.edu ".

    Sending automatic responses via vacation>

    Ever wish you could have email send automatic messages as replies to those received while you are unavailable to answer personally? Going on vacation is a good example. You don't want your correspondents to think you're ignoring them, but you're also not in a position to get back to them for some time to come. You could always change your PhoneMail greeting, but many people will not think to check that. The perfect solution: Unix's vacation program. It is simple to use, being a matter of setting up or changing a couple of short files.

    In your Unix home directory, create a file called .vacation.msg to contain your own email address and the message you'd like delivered to all those who write to you. To illustrate, your .vacation.msg file might contain the following:

              
         From: smith@umbc.edu
      Subject: Out of the Office
              
    Hello. I will be away from the office from March 1st through the 15th.
    I will return your message as soon as I'm back. If the matter is urgent,
    please call  ext. 9999 or send another email message to jones@umbc.edu.
      
                     -Annabelle Smith-
    

    Then, at the system prompt, enter vacation -i to initialize the program's database. Finally, either create or edit another file in your home directory named .forward. Add or create the line

    \smith, | "/usr/sbin/vacation smith"
    Remember to put your account name in place of both smith's in the example line above.

    This will cause incoming mail to be sent to the vacation program as well as to your mailbox, and will reply with your customized message. Remember to delete the above line from your .forward file upon your return so that no more automatic messages are sent. For more information on this, see the Unix man page for vacation.