Next: , Up: Rmail

33.1 Basic Concepts of Rmail

Using Rmail in the simplest fashion, you have one Rmail file ~/RMAIL in which all of your mail is saved. It is called your primary Rmail file. The command M-x rmail reads your primary Rmail file, merges new mail in from your inboxes, displays the first message you haven't read yet, and lets you begin reading. The variable rmail-file-name specifies the name of the primary Rmail file.

Rmail displays only one message in the Rmail file at a time. The message that is shown is called the current message. Rmail mode's special commands can do such things as delete the current message, copy it into another file, send a reply, or move to another message. You can also create multiple Rmail files and use Rmail to move messages between them.

Within the Rmail file, messages are normally arranged sequentially in order of receipt; you can specify other ways to sort them (see Rmail Sorting). Messages are identified by consecutive integers which are their message numbers. The number of the current message is displayed in Rmail's mode line, followed by the total number of messages in the file. You can move to a message by specifying its message number with the j key (see Rmail Motion).

Following the usual conventions of Emacs, changes in an Rmail file become permanent only when you save the file. You can save it with s (rmail-expunge-and-save), which also expunges deleted messages from the file first (see Rmail Deletion). To save the file without expunging, use C-x C-s. Rmail also saves the Rmail file after merging new mail from an inbox file (see Rmail Inbox).

You can exit Rmail with q (rmail-quit); this expunges and saves the Rmail file, then buries the Rmail buffer as well as its summary buffer, if present (see Rmail Summary). But there is no need to exit formally. If you switch from Rmail to editing in other buffers, and never switch back, you have exited. Just make sure to save the Rmail file eventually (like any other file you have changed). C-x s is a suitable way to do this (see Save Commands). The Rmail command b, rmail-bury, buries the Rmail buffer and its summary without expunging and saving the Rmail file.