Rmail has several commands to send outgoing mail. See Sending Mail, for information on using Message mode, including certain features meant to work with Rmail. What this section documents are the special commands of Rmail for entering the mail buffer. Note that the usual keys for sending mail—C-x m, C-x 4 m, and C-x 5 m—also work normally in Rmail mode.
Send a message (
Continue editing the already started outgoing message (
Send a reply to the current Rmail message (
Forward the current message to other users (
Resend the current message to other users (
Try sending a bounced message a second time (
The most common reason to send a message while in Rmail is to reply
to the message you are reading. To do this, type r
rmail-reply). This displays a mail composition buffer in
another window, much like C-x 4 m, but preinitializes the
‘Subject’, ‘To’, ‘CC’, ‘In-reply-to’ and
‘References’ header fields based on the message you are replying
to. The ‘To’ field starts out as the address of the person who
sent the message you received, and the ‘CC’ field starts out with
all the other recipients of that message.
You can exclude certain recipients from being included automatically
in replies, using the variable
value should be a regular expression; any recipients that match are
excluded from the ‘CC’ field. They are also excluded from the
‘To’ field, unless this would leave the field empty. If this
nil, then the first time you compose a reply it is
initialized to a default value that matches your own address.
To omit the ‘CC’ field completely for a particular reply, enter the reply command with a numeric argument: C-u r or 1 r. This means to reply only to the sender of the original message.
Once the mail composition buffer has been initialized, editing and sending the mail goes as usual (see Sending Mail). You can edit the presupplied header fields if they are not what you want. You can also use commands such as C-c C-y, which yanks in the message that you are replying to (see Mail Commands). You can also switch to the Rmail buffer, select a different message there, switch back, and yank the new current message.
Sometimes a message does not reach its destination. Mailers usually
send the failed message back to you, enclosed in a failure
message. The Rmail command M-m (
prepares to send the same message a second time: it sets up a
mail composition buffer with the same text and header fields as before. If
you type C-c C-c right away, you send the message again exactly
the same as the first time. Alternatively, you can edit the text or
headers and then send it. The variable
rmail-retry-ignored-headers, in the same format as
rmail-ignored-headers (see Rmail Display), controls which
headers are stripped from the failed message when retrying it.
Another frequent reason to send mail in Rmail is to forward the
current message to other users. f (
this easy by preinitializing the mail composition buffer with the current
message as the text, and a subject of the form
subject], where from and subject are the sender and
subject of the original message. All you have to do is fill in the
recipients and send. When you forward a message, recipients get a
message which is from you, and which has the original message in
Rmail offers two formats for forwarded messages. The default is to
use MIME (see Rmail Display) format. This includes the original
message as a separate part. You can use a simpler format if you
prefer, by setting the variable
nil. In this case, Rmail just includes the original message
enclosed between two delimiter lines. It also modifies every line
that starts with a dash, by inserting ‘- ’ at the start of
the line. When you receive a forwarded message in this format, if it
contains something besides ordinary text—for example, program source
code—you might find it useful to undo that transformation. You can
do this by selecting the forwarded message and typing M-x
unforward-rmail-message. This command extracts the original
forwarded message, deleting the inserted ‘- ’ strings, and
inserts it into the Rmail file as a separate message immediately
following the current one.
Resending is an alternative similar to forwarding; the
difference is that resending sends a message that is from the
original sender, just as it reached you—with a few added header fields
(‘Resent-From’ and ‘Resent-To’) to indicate that it came via
you. To resend a message in Rmail, use C-u f. (f runs
rmail-forward, which invokes
rmail-resend if you provide a
Use the m (
rmail-mail) command to start editing an
outgoing message that is not a reply. It leaves the header fields empty.
Its only difference from C-x 4 m is that it makes the Rmail buffer
accessible for C-c C-y, just as r does.
The c (
rmail-continue) command resumes editing the
mail composition buffer, to finish editing an outgoing message you were
already composing, or to alter a message you have sent.
If you set the variable
rmail-mail-new-frame to a
nil value, then all the Rmail commands to start sending a
message create a new frame to edit it in. This frame is deleted when
you send the message.
All the Rmail commands to send a message use the mail-composition method that you have chosen (see Mail Methods).