Sending Mail from Within Emacs
Sending mail from inside Emacs is easy. To send a message, type
C-x m, which brings you into an Emacs-created buffer called
*mail*
.
Type: C-x m
You’re ready to type a mail message.
Type the email address of the person you’re sending mail to in the
To:
field, then the subject, if you want to, on the next line.
You can send a single message to several recipients by putting many
addresses on the To
: line. Make sure you put a comma between
each address. If you have more than one line of recipients, leave a
blank space on the second and subsequent lines and keep typing (this
works for all the fields you can put email addresses in, such as
CC
: and BCC
: fields which we’ll discuss shortly).
When you’re ready to write the body of the message, move the cursor
below the --text follows this line--
message and write
your message as you would any Emacs file. Don’t erase or modify the
marker --text follows this line--
; Emacs needs it to
divide the header from the body of the message and breaks if you erase
it. This message won’t be sent with your mail; it only shows you
where the mail’s header (the recipients, the subject, etc.) ends and
the text begins.
While you’re writing the message, you can use any of Emacs’ features, including the spell checker, abbreviation mode, and so on. When you’re finished, you can send the message by typing C-c C-c or by selecting ...
Get Learning GNU Emacs, Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.