GNU Emacs Manual - Rmail Labels

Go to the first, previous, next, last section, table of contents.

## Labels

Each message can have various labels assigned to it as a means of classification. Each label has a name; different names are different labels. Any given label is either present or absent on a particular message. A few label names have standard meanings and are given to messages automatically by Rmail when appropriate; these special labels are called attributes. All other labels are assigned only by users.

`a label `RET``
  Assign the label label to the current message (`rmail-add-label`).
`k label `RET``
  Remove the label label from the current message (`rmail-kill-label`).
`C-M-n labels `RET``
  Move to the next message that has one of the labels labels (`rmail-next-labeled-message`).
`C-M-p labels `RET``
  Move to the previous message that has one of the labels labels (`rmail-previous-labeled-message`).
`C-M-l labels `RET``
  Make a summary of all messages containing any of the labels labels (`rmail-summary-by-labels`).

The `a` (`rmail-add-label`) and `k` (`rmail-kill-label`) commands allow you to assign or remove any label on the current message. If the label argument is empty, it means to assign or remove the same label most recently assigned or removed.

Once you have given messages labels to classify them as you wish, there are two ways to use the labels: in moving and in summaries.

The command `C-M-n labels `RET`` (`rmail-next-labeled-message`) moves to the next message that has one of the labels labels. The argument labels specifies one or more label names, separated by commas. `C-M-p` (`rmail-previous-labeled-message`) is similar, but moves backwards to previous messages. A numeric argument to either command serves as a repeat count.

The command `C-M-l labels `RET`` (`rmail-summary-by-labels`) displays a summary containing only the messages that have at least one of a specified set of labels. The argument labels is one or more label names, separated by commas. See section Summaries, for information on summaries.

If the labels argument to `C-M-n`, `C-M-p` or `C-M-l` is empty, it means to use the last set of labels specified for any of these commands.

Go to the first, previous, next, last section, table of contents.