Computing Topics --> Help With Application Programs --> E-mail Applications --> Pine (for reading mail over telnet/SSH) --> Handling Entire Message Groups at Once in Pine -->

Handling Entire Message Groups at Once in Pine

Pine's "Aggregate Command Set"

Pine has a very powerful feature called the "aggregate command set", which makes it possible to select a group of messages based on something they have in common (date range, number range, subject line, to line, from line, text in the message, etc.), and then apply a command to all of them (save, delete, etc.).

Turning on the Aggregate Command Set

If you do not already have the command enabled on your version of pine here is how to do so:

  1. Type m to get to the main menu of pine.
  2. Type s to bring up pine's setup menu.
  3. Type c to go to the configure menu for pine.
  4. Type ^w to bring up the "Word to find" command.
  5. In the space provided type agg to search for the line that has "enable-aggregate-command-set" on it.
  6. If there is an X next to the command in the brackets then it is already enabled. If not, then type x to enable the command.
  7. Now type e to exit the config menu.
  8. When prompted to save your changes, type y for yes to save them.

An Example, How to delete a selected group of messages

As mentioned above, there are a variety of characteristics that you can use to group messages for selection. Example:

You've received a lot of messages from a discussion list that you haven't had time to read. You want to get rid of all of those that are out of date. Let's say the list is "cheaptalk-l@somewhere.edu", and anything before December 1997 is out of date.

We're looking for two features that are common to all the messages you want to get rid of:

  • the list address, which will be text found on the To: line of every message sent to the list, and
  • the date the message was received, with respect to December, 1997.

Here's the method for isolating these messages, starting while you're in the Folder Index (message list):

  1. Make sure that you are in the message index by typing i or by typing l to select a different folder.
  2. Type ; which activates the select command.
  3. Type t which tells pine to use test for the selection criteria.
  4. Type t again which narrows the text searched to the To: line of the messages.
  5. Type cheaptalk which is the text that you want to find.

At this point, all the messages from the group will be marked at the left with an X. You could use the Z(oom) command to toggle between displaying only the selected messages and displaying all the messages. If you just wanted ALL the messages from the group, you'd be finished, but in this case, we want to NARROW the search to include ONLY the ones BEFORE December 1, 1997. So we do another selection process on the ones we've already selected:

  1. Type ; to bring up the selection menu.
  2. Now type an n in order to narrow the selection.
  3. Type a d to select messages by date.
  4. To toggle the date selection between ON, SINCE, or BEFORE, type ^w. In this case we want to select BEFORE so toggle the message until BEFORE is selected.
  5. Now type in the date 1-Dec-1997.

At this point, all the X'd items from on or after 12/31/97 become un-X'd.

Now to DO something with the selection

Our example calls for us to delete these messages. We do this by using the append command which is the other command of the aggregate command set.

  1. Type a to apply a command to the selected messages.
  2. Now type a d to mark the selected messages for deletion.
  3. To finish the delete immediately, type x to expunge the messages from the message folder.
  4. To finish the process type y for yes to expunge the messages.

And that finishes the job.

For more information about these commands

The Aggregate Command Set is even more powerful than what we've just show above. For more information about it,

  1. Type a ? to ask for help.
  2. Now bring up the search feature by typing w.
  3. In the space provided type selecting to go to the topic called selecting which covers this topic.
How do I:
How are we doing? Comments on this page?
Office of Information Technology
Office of Information Technology University of Maryland