2011-12-14 08:11:40 +01:00
|
|
|
\input texinfo.tex @c -*-texinfo-*-
|
|
|
|
@c %**start of header
|
|
|
|
@setfilename mu4e.info
|
|
|
|
@settitle mu4e user manual
|
|
|
|
@documentencoding utf-8
|
|
|
|
@c %**end of header
|
|
|
|
|
|
|
|
@dircategory Emacs
|
|
|
|
@direntry
|
2011-12-17 10:33:50 +01:00
|
|
|
* mu4e: (mu4e). An email client for emacs based on mu.
|
2011-12-14 08:11:40 +01:00
|
|
|
@end direntry
|
|
|
|
|
|
|
|
@copying
|
|
|
|
Copyright @copyright{} 2011 Dirk-Jan C. Binnema
|
|
|
|
|
|
|
|
@quotation
|
|
|
|
Permission is granted to copy, distribute and/or modify this document
|
|
|
|
under the terms of the GNU Free Documentation License, Version 1.2 or
|
|
|
|
any later version published by the Free Software Foundation; with no
|
|
|
|
Invariant Sections, with no Front-Cover Texts, and with no Back-Cover
|
|
|
|
Texts.
|
|
|
|
@end quotation
|
|
|
|
@end copying
|
|
|
|
|
|
|
|
@node Top
|
2011-12-17 10:33:50 +01:00
|
|
|
@top mu4e Manual
|
2011-12-14 08:11:40 +01:00
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@emph{Mu-For-Emacs} (or for short, @command{mu4e}), is an @command{emacs} based
|
|
|
|
e-mail client, based on the @command{mu} e-mail search engine. @command{mu4e}
|
|
|
|
supports GNU Emacs 23 and later.
|
2011-12-14 08:11:40 +01:00
|
|
|
|
|
|
|
@menu
|
|
|
|
* Introduction::
|
2011-12-17 10:33:50 +01:00
|
|
|
* Getting started::
|
|
|
|
* Running mu4e::
|
|
|
|
@c * Getting mail::
|
|
|
|
@c * Searching mail::
|
|
|
|
@c * Reading mail::
|
|
|
|
@c * Processing mail::
|
|
|
|
@c * Sending mail::
|
2011-12-14 08:11:40 +01:00
|
|
|
* Example configuration::
|
|
|
|
@end menu
|
|
|
|
|
|
|
|
@node Introduction
|
|
|
|
@chapter Introduction
|
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@command{mu4e} is an e-mail program for GNU Emacs; it uses the @command{mu}
|
|
|
|
e-mail search engine as its backend, making @command{mu} fully search-based.
|
2011-12-14 08:11:40 +01:00
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@command{mu4e} (and @command{mu}) does @emph{not} deal with getting your
|
|
|
|
e-mail messages from some e-mail server; instead, this task is delegated to
|
|
|
|
other tools, such as @command{offlineimap}. As long as the messages end up in
|
|
|
|
a Maildir, @command{mu4e}/@command{mu} are happy to deal with them.
|
2011-12-14 08:11:40 +01:00
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@command{mu4e} does @emph{not} implement sending messages either; instead, it
|
2011-12-14 08:11:40 +01:00
|
|
|
depends on the true-and-tested @emph{smtpmail} which is part of emacs. In
|
2011-12-17 10:33:50 +01:00
|
|
|
fact, @command{mu4e} piggybacks on @ref{Top, Gnus} for its message editor.
|
2011-12-14 08:11:40 +01:00
|
|
|
|
|
|
|
Thus, many of the traditional things an e-mail client needs to do, are
|
2011-12-17 10:33:50 +01:00
|
|
|
subcontracted to other tools. This leaves @command{mu4e} to concentrate on
|
|
|
|
what it does best: quick message searching, reading mails, replying them,
|
|
|
|
moving messages around and so on.
|
2011-12-14 08:11:40 +01:00
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
It's important to note the @command{mu4e} requires your mail to be in
|
|
|
|
Maildir-format, typically stored in @file{~/Maildir}.
|
2011-12-14 08:11:40 +01:00
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@c @section Acknowledgments
|
|
|
|
|
|
|
|
@command{mu} has been helped tremendously by users who helped to isolate and fix
|
2011-12-14 08:11:40 +01:00
|
|
|
bugs, and (maybe even more so) by providing suggestions. Thanks to all!
|
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@command{mu4e} has taken inspiration from many places. First, there are @command{sup}
|
|
|
|
and @command{notmuch} which showed that one can write a search-based e-mail
|
2011-12-14 08:11:40 +01:00
|
|
|
client. Aspects of the Wanderlust e-mail client can be seen in the UI, as well
|
2011-12-17 10:33:50 +01:00
|
|
|
as the @command{dired} interaction model.
|
|
|
|
|
|
|
|
@node Getting started
|
|
|
|
@chapter Getting started
|
|
|
|
|
|
|
|
Getting started.
|
2011-12-14 08:11:40 +01:00
|
|
|
|
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@c @section Installation
|
|
|
|
|
|
|
|
@command{mu4e} is part of @command{mu} - by installing the latter, the former will
|
2011-12-14 08:11:40 +01:00
|
|
|
be installed as well.
|
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
At the time of writing, there are no distribution packages for @command{mu4e}
|
2011-12-14 08:11:40 +01:00
|
|
|
yet, so we are assuming installation from source packages.
|
|
|
|
|
|
|
|
Installation follows the normal sequence of:
|
|
|
|
@example
|
2011-12-17 10:33:50 +01:00
|
|
|
$ tar xvfz mu-<version>.tar.gz # use the specific version
|
|
|
|
$ cd mu-<version>
|
2011-12-14 08:11:40 +01:00
|
|
|
$./configure && make
|
|
|
|
$ sudo make install
|
|
|
|
@end example
|
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
After this, @command{mu} and @command{mu4e} should be
|
|
|
|
installed @footnote{there's a hard dependency between versions of
|
|
|
|
@command{mu4e} and @command{mu} - you cannot combine different versions.}, a
|
|
|
|
be available from the command line and emacs (respectively). For emacs, you
|
|
|
|
may to restart it so it can pick up @command{mu4e}.
|
|
|
|
|
|
|
|
There is experimental support for using the @command{emacs} customization
|
|
|
|
system in @command{mu4e}, but for now we recommend setting the values by
|
|
|
|
manually. Please @ref{Example configuration} for a working example of this.
|
|
|
|
|
|
|
|
@c @node Getting mail
|
|
|
|
@c @section Getting mail
|
|
|
|
|
|
|
|
In order for @command{mu} (and by extension, @command{mu4e}) to work, we need
|
|
|
|
to have our e-mail stored in a Maildir. If you were already using Maildirs,
|
|
|
|
your lucky, otherwise you will need to get your mail there in some other way.
|
|
|
|
|
|
|
|
If you are using some external @acronym{IMAP} or @acronym{POP} server, you can
|
|
|
|
use tools like @command{getmail} and @command{offlineimap} to download your
|
|
|
|
message into a Maildir-directory (@file{~/Maildir}, usually). If you are using
|
|
|
|
a local mailserver (such as Postfix or @command{qmail}), you can teach them to
|
|
|
|
deliver into a Maildir as well, maybe in combination with @command{qmail}.
|
|
|
|
|
|
|
|
For the exact details on how to do this, please consult the documentation of
|
|
|
|
the products you are using.
|
|
|
|
|
|
|
|
@c @node Indexing your messages
|
|
|
|
@c @section Indexing your messages
|
|
|
|
@c @ref{Getting mail}
|
|
|
|
After you have succeeded in Getting mail, we need to @emph{index}
|
|
|
|
it. That is - we need to scan the Maildir and store the information about the
|
|
|
|
mails into a special database. We can do that from @code{mu4e}, but for now
|
|
|
|
it's better to do it from the command line, because it's easier to spot any
|
|
|
|
problems then.
|
|
|
|
|
|
|
|
Assuming that your Maildir is at @file{~/Maildir}, you should give the
|
|
|
|
following command:
|
|
|
|
@example
|
|
|
|
$ mu index --maildir=~/Maildir
|
|
|
|
@end example
|
|
|
|
|
|
|
|
This should scan your @file{~/Maildir} and fill the database, and give
|
|
|
|
progress information while doing so. The first time you index your mail might
|
|
|
|
take a few minutes (for thousands of e-mails), afterwards it is much faster
|
|
|
|
since it only has to scan the differences.
|
|
|
|
|
|
|
|
Note that indexing is discussed at length in the @command{mu-index} man page.
|
|
|
|
|
|
|
|
After the indexing is finished, you can quickly test if everything worked, by
|
|
|
|
trying some command line searches, for example
|
|
|
|
@example
|
|
|
|
$ mu find hello
|
|
|
|
@end example
|
|
|
|
which should list all messages that match "hello". The @command{mu-find} man
|
|
|
|
page describes the various things you can do with @command{mu find}.
|
2011-12-14 08:11:40 +01:00
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
If all of this worked well, we are almost ready to start @command{mu4e}.
|
2011-12-14 08:11:40 +01:00
|
|
|
|
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@c @node Basic configuration
|
|
|
|
@c @section Basic configuration
|
|
|
|
|
|
|
|
The last thing to do before running @command{mu4e} is setting up some basic
|
|
|
|
configuration. A good place to put this would be in your @file{~/.emacs} file.
|
|
|
|
|
|
|
|
First, we need to load @command{mu4e}:
|
|
|
|
|
|
|
|
@example
|
|
|
|
(require 'mu4e)
|
|
|
|
@end example
|
|
|
|
|
|
|
|
Then, we need to tell @command{mu4e} where it can find your Maildir, and some
|
|
|
|
special folders. So for example:
|
|
|
|
@example
|
|
|
|
(setq
|
|
|
|
mu4e-maildir "~/Maildir"
|
|
|
|
mu4e-inbox-folder "/inbox" ;; where do i receive mail?
|
|
|
|
mu4e-sent-folder "/sent" ;; where do i keep sent mail?
|
|
|
|
mu4e-drafts-folder "/drafts" ;; where do i keep half-written mail?
|
|
|
|
mu4e-trash-folder "/trash" ;; where do i move deleted mail?
|
|
|
|
@end example
|
|
|
|
The folder names are all relative to @code{mu4e-maildir}.
|
|
|
|
|
2011-12-14 08:11:40 +01:00
|
|
|
|
|
|
|
Without going into too much technical detail, here we describe the elements in
|
2011-12-17 10:33:50 +01:00
|
|
|
a @command{mu4e}-setup, and how they work together. Using some ascii-art:
|
2011-12-14 08:11:40 +01:00
|
|
|
|
|
|
|
@example
|
|
|
|
+---------+
|
|
|
|
| emacs |
|
|
|
|
| +------+
|
|
|
|
+----| mu4e | --> send mail (smtpmail)
|
|
|
|
+------+
|
|
|
|
| A
|
|
|
|
V |
|
|
|
|
+---------+
|
|
|
|
| mu |
|
|
|
|
+---------+
|
|
|
|
| A
|
|
|
|
V |
|
|
|
|
+---------+
|
|
|
|
| Maildir | <--- receive mail (fetchmail,
|
|
|
|
+---------+ offlineimap, ...)
|
|
|
|
@end example
|
|
|
|
|
|
|
|
So:
|
|
|
|
@itemize
|
|
|
|
|
|
|
|
@item Your e-mail messages are stored in a Maildir-directory (typically,
|
2011-12-17 10:33:50 +01:00
|
|
|
@file{~/Maildir}), and new mail comes in using tools like @command{fetchmail},
|
|
|
|
@command{offlineimap} etc., or through a local mail servers (such as
|
|
|
|
@command{qmail} or @command{Postfix}).
|
2011-12-14 08:11:40 +01:00
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@item @command{mu} indexes these messages periodically, so you can quickly
|
|
|
|
search for them. @command{mu} can run in a special @command{server}-mode, where it
|
2011-12-14 08:11:40 +01:00
|
|
|
provides services to client software.
|
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@item @command{mu4e}, which runs inside @command{emacs} is such a client; it
|
|
|
|
communicates with @command{mu} to search for messages, and manipulate them.
|
2011-12-14 08:11:40 +01:00
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@item @command{mu4e} uses the facilities offered by @command{emacs} (the
|
|
|
|
@command{Gnus} message editor and @command{smtpmail}) to send messages.
|
2011-12-14 08:11:40 +01:00
|
|
|
|
|
|
|
@end itemize
|
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
|
2011-12-14 08:11:40 +01:00
|
|
|
@example
|
|
|
|
+-----------+ +--------------+ +--------------+
|
|
|
|
| main view | <---> | headers view | <---> | message view |
|
|
|
|
+-----------+ +--------------+ +--------------+
|
|
|
|
|
|
|
|
|
+----------+
|
|
|
|
| raw view |
|
|
|
|
+----------+
|
|
|
|
@end example
|
|
|
|
|
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@node Running mu4e
|
|
|
|
@chapter Running mu4e
|
|
|
|
|
|
|
|
After you've installed @command{mu4e} (@pxref{Getting started}), you can start it
|
|
|
|
with @code{M-x mu4e}. This will do some checks to ensure everything is set up
|
|
|
|
correctly, and then show the @command{mu4e} main view.
|
|
|
|
|
|
|
|
@verbatim
|
|
|
|
* mu4e - mu for emacs version 0.9.8pre
|
|
|
|
|
|
|
|
Basics
|
|
|
|
|
|
|
|
* [j]ump to some maildir
|
|
|
|
* enter a [s]earch query
|
|
|
|
* [c]ompose a new message
|
|
|
|
|
|
|
|
Bookmarks
|
|
|
|
|
|
|
|
* [bu] Unread messages
|
|
|
|
* [bt] Today's messages
|
|
|
|
* [bw] Last 7 days
|
|
|
|
* [bp] Messages with images
|
|
|
|
Misc
|
|
|
|
|
|
|
|
* [u]pdate email & database
|
|
|
|
* toggle [m]ail sending mode (direct)
|
|
|
|
* [f]lush queued mail
|
|
|
|
|
|
|
|
* [q]uit mm
|
|
|
|
|
|
|
|
@end verbatim
|
2011-12-14 08:11:40 +01:00
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
First, the @emph{Basics}:
|
|
|
|
@itemize
|
|
|
|
@item @code{[j]ump to some maildir} means that after pressing @key{j},
|
|
|
|
@command{mu4e} will ask you for a maildir to jump to.
|
|
|
|
@end itemize
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@c @node Getting mail
|
|
|
|
@c @section Getting mail
|
|
|
|
|
|
|
|
@command{mu} works with whatever it finds in your Maildir, without caring much
|
2011-12-14 08:11:40 +01:00
|
|
|
how the mail got there. Typical ways to do so are using @code{fetchmail} or
|
|
|
|
@code{offlineimap}, but mail servers like @code{qmail} or @code{Postfix} can
|
|
|
|
deliver mail in a Maildir as well. Please refer to the documentation for these
|
|
|
|
tools.
|
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@command{mu4e} checks the setting of the @env{MAILDIR} environment variable to
|
2011-12-14 08:11:40 +01:00
|
|
|
locate the Maildir; if that is not set, if falls back to @code{~/Maildir}. If
|
|
|
|
you want to use some other directory, you can customize @code{mu4e-mu-home}.
|
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
To invoke some mail-getting command from the @command{mu4e} main screen, you can
|
2011-12-14 08:11:40 +01:00
|
|
|
call @code{mu4e-retrieve-mail-update-db} (by default @kbd{u}); to use it, you
|
|
|
|
should set @code{mu4e-get-mail-command} to some shell command.
|
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@c @node Searching mail
|
|
|
|
@c @section Searching mail
|
2011-12-14 08:11:40 +01:00
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@command{mu4e} is full search-based; this means that all the lists of messages
|
2011-12-14 08:11:40 +01:00
|
|
|
you see, are the result of some query. Even if you 'jump to a folder', in fact
|
|
|
|
you are executing a search query for messages that have the property of being
|
|
|
|
in a certain folder.
|
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@c @node Reading mail
|
|
|
|
@c @section Reading mail
|
2011-12-14 08:11:40 +01:00
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@c @node Processing mail
|
|
|
|
@c @section Processing mail
|
2011-12-14 08:11:40 +01:00
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@c Processing mail is the act of moving mails around (in folders), viewing them
|
2011-12-14 08:11:40 +01:00
|
|
|
|
2011-12-17 10:33:50 +01:00
|
|
|
@c @node Sending mail
|
|
|
|
@c @section Sending mail
|
2011-12-14 08:11:40 +01:00
|
|
|
|
|
|
|
|
|
|
|
@node Example configuration
|
|
|
|
@chapter Example configuration
|
|
|
|
|
|
|
|
@example
|
|
|
|
@verbatim
|
|
|
|
;; example configuration for mu-for-emacs (mu4e)
|
|
|
|
|
|
|
|
(require 'mu4e)
|
|
|
|
(load-library "smtpmail")
|
|
|
|
|
|
|
|
(setq
|
|
|
|
;; a regular expression that matches all email address uses by the user;
|
|
|
|
;; this allows us to correctly determine if user is the sender of some message
|
|
|
|
mu4e-user-mail-address-regexp
|
|
|
|
"foo@bar\.com\\|cuux@example\.com"
|
|
|
|
|
|
|
|
mu4e-maildir "/home/user/Maildir"
|
|
|
|
;; the next are relative to `mu4e-maildir'
|
|
|
|
mu4e-outbox-folder "/outbox"
|
|
|
|
mu4e-sent-folder "/sent"
|
|
|
|
mu4e-drafts-folder "/drafts"
|
|
|
|
mu4e-trash-folder "/trash"
|
|
|
|
|
|
|
|
;; the maildirs you use frequently; access them with 'j' ('jump')
|
|
|
|
mu4e-maildir-shortcuts
|
|
|
|
'( ("/archive" . ?a)
|
|
|
|
("/inbox" . ?i)
|
|
|
|
("/work" . ?w)
|
|
|
|
("/sent" . ?s))
|
|
|
|
|
|
|
|
;; program to get mail
|
|
|
|
mu4e-get-mail-command "fetchmail"
|
|
|
|
|
|
|
|
;; general emacs mail settings
|
|
|
|
mail-reply-to "foo@bar.com"
|
|
|
|
user-mail-address "foo@bar.com"
|
|
|
|
user-full-name "Foo. X Bar"
|
|
|
|
|
|
|
|
;; include in message with C-c C-w
|
|
|
|
message-signature
|
|
|
|
(concat
|
|
|
|
"Foo X. Bar\n"
|
|
|
|
"http://www.example.com\n")
|
|
|
|
|
|
|
|
;; smtp mail setting
|
|
|
|
message-send-mail-function 'smtpmail-send-it
|
|
|
|
smtpmail-default-smtp-server "smtpa.example.com"
|
|
|
|
smtpmail-smtp-server ""smtpa.example.com"
|
|
|
|
smtpmail-local-domain "example.com"
|
|
|
|
|
|
|
|
;; for offline mode
|
|
|
|
smtpmail-queue-mail nil
|
|
|
|
smtpmail-queue-dir "/home/user/Maildir/queue/cur")
|
|
|
|
@end verbatim
|
|
|
|
@end example
|
|
|
|
|
|
|
|
|
|
|
|
@bye
|