Using Sequences

Expanded support for sequences is new in exmh version 2.6.3. The information on this page does not apply to releases prior to 2.6.3.

We've always had the the 'unseen' sequence, and I'm sure most are familiar with the Unseen Window to note how many unread messages there are left to go through. With the 2.6.3 release, the Unseen Window is replaced by the more general Sequences Window. Also new is the ability to create new sequences and manage them using exmh.

Think of Sequences as a new way to categorize your e-mail. For example, you may want have several e-mails you know need to respond to, but can't do so until you gather a bunch of information. Or, you need to remember where a certain message is because it contains information you need to refer later while working on some project. This is where Sequences come in handy.

As Hal DeVore stated on the exmh-users list:

	Think of it as being able to attach any number of arbitrary
	labels to a message.  Then all the messages that have the same
	label are members of a sequence.

There are two sequences that are somewhat pre-defined in exmh as it comes "out of the box". Those are "unseen" and "urgent". The "unseen" sequence is, of course, the usual name of the sequence that MH/nmh and exmh use to track unread mail messages. The "urgent" sequence may be useful to you but is sort of a "starter" sequence to help you learn how to use them.

In addition to the pre-defined sequences there are a number of things that aren't actually sequences (i.e., don't necessarily get recorded in the .mh_sequences file for a folder) but that exmh treats as sequences for formatting. These "pseudo-sequences" are:

  1. "cur" which notes the current message. The current message is stored in the .mh_sequences file for a folder, the remaining "pseudo-sequences" are not stored anywhere.
  2. "deleted" which tracks messages that have been marked for deletion
  3. "moved" which tracks messages that have been marked for moving to another folder
  4. "selected" which is messages that have been selected, for example by dragging the mouse pointer across a range of messages in the folder TOC.
  5. "mrange", "drange", and "range" (dunno, need to figure these out)

I use 3 different sequences (for now): unseen, followup, and reply. Obviosly 'unseen' is for my unread e-mail. I use 'followup' to mark e-mails which require me to take some kind of action, and 'reply' to mark those e-mails which I know I need to respond to, but just haven't gotten around to yet. You can come up with any type of labels you want to indicate the importance or meaning of messages based on how you manage e-mail. Like everything else in exmh, sequences are infinitely flexible :)

To add the new sequences, exit exmh and edit your ~/.exmh/exmh-defaults file to add lines like this:

       *sequence_followup: -foreground white -background black
       *sequence_reply: -foreground green -background black

       *sequences: followup reply urgent mrange drange range moved \
        deleted selected unseen cur

(note: that last line should be one continuous line. I broke it up to fit the page better.)

Once you've added these lines to your ~/.exmh/exmh-defaults file, restart exmh, and you should be ready to start using sequences.

Take special note of the last line. This does two things:

  1. This defines the order in which the formatting will be applied. The last sequence in the list "wins", i.e., the value of an attribute associated with that sequence will be used. If a sequence or pseudo-sequence is not included in the list then formatting for that sequence will never be applied. So, for example, if you leave "deleted" out of the list you won't be able to see that a message is pending deletion.
  2. Sequence names other than the "pseudo-sequences" that are listed here will be added to the Sequences... menu.

The lines that begin "*sequence_" followed by a sequence name set the formatting attributes for the named sequence. The formatting attributes apply to the message in the folder TOC and to the section of the Sequences Window where info on the sequence is displayed. The useful attributes that you can apply are:

The default formatting for the built-in sequences and the pseudo-sequences can be found in the app-defaults-color file in the lib directory of your installed copy of exmh.

For more explanation about what all this means, read Hal's explanation.

To remove a message from a sequence:


"Temporary" sequences

It's not necessary to set special formatting for sequences to be useful. One of the other things sequences are useful for is temporarily keeping track of a set of messages in a folder. You can assign messages to a sequence using the nmh/MH pick command.

    folder +inbox
    pick -from theboss -sequence ignorethese

You can also use the Search menu in exmh. Select the "All messages in current folder (pick)" item.

After pick has created a sequence, its name will appear in the Sequences window. If you set your Sequences preferences to include a button that performs a "Warp and Narrow" operation then you can "narrow" the folder TOC to only include messages in the selected sequence.

To remove messages from the sequence use the nmh/MH mark command. For example to remove all messages from the sequence "ignorethese" (note this does not delete the message, just removes the "label"):

    mark -sequence ignorethese -delete all


Updated on 12 Dec 2003, 01:46 GMT
Search - Recent Changes - Reference - Index - Go to Beedub's Wiki - Help