The next two items in the Main view are Bookmarks and Maildirs.
Bookmarks are predefined queries with a descriptive name and a shortcut. In the example above, we see the default bookmarks. You can pick a bookmark by pressing b followed by the specific bookmark’s shortcut. If you want to edit the bookmarked query before invoking it, use B.
Next to each bookmark are some numbers that indicate the unread(delta)/all matching messages for the given query, with the delta being the difference in unread count since some “baseline”, and only shown when this delta > 0.
Note that the “delta” has its limitations: if you, for instance, deleted 5
messages and received 5 new one, the “delta” would be 0, although there were
changes indeed. So it is mostly useful for tracking changes while you are
not using mu4e
. For this reason, you can reset the baseline manually,
e.g. by visiting the main view .
By comparing current results with the baseline, you can quickly what new messages have arrived since the last time you looked.
The baseline5 . is reset
automatically when switching to the main view, or invoking buffer-revert
(g) while in the main-view. Visiting the “favorite” bookmark does the
same(explained below).
Bookmarks are stored in the variable mu4e-bookmarks
; you can add
your own and/or replace the default ones; See Bookmarks. For
instance:
(add-to-list 'mu4e-bookmarks ;; add bookmark for recent messages on the Mu mailing list. '( :name "Mu7Days" :key ?m :query "list:mu-discuss.googlegroups.com AND date:7d..now"))
There are optional keys :hide
to hide the bookmark from the main menu, but
still have it available (using b)) and :hide-unread
to avoid
generating the unread-number; that can be useful if you have bookmarks for slow
queries. Note that :hide-unread
is implied when the query is not a string;
this for the common case where the query function involves some user input,
which would be disruptive in this case.
There is also the optional :favorite
property, which at most one bookmark
should have; this bookmark is highlighted in the main view, and its
unread-status is shown in the modeline; See Modeline, and you can enable
desktop notifications; See Desktop notifications. We’d recommend creating
such a “favorite”, which should match message that require your quick
attention:
(add-to-list 'mu4e-bookmarks ;; bookmark for message that require quick attention '( :name "Urgent" :key ?u :query "maildir:/inbox AND from:boss@exmaple.com"))
Note that mu4e
resets the baseline when you are interacting with it (for
instance, when you visit the urgent bookmark, or when you go to the main view);
in such cases, there won’t be any further notifications.
The Maildirs item is very similar to Bookmarks – consider maildirs here
as being a special kind of bookmark query that matches a Maildir. You can
configure this using the variable mu4e-maildir-shortcuts
; see its
docstring and Maildir searches for more details.
For debugging, it can be useful to see the time for the
baseline - for that, there is the mu4e-baseline-time
command