You can navigate through previous/next queries using
mu4e-headers-query-next, which are
bound to M-left and M-right, similar to what some web browsers do.
mu4e tries to be smart and not record duplicate queries. Also, the number of queries remembered has a fixed limit, so mu4e won’t use too much memory, even if used for a long time. However, if you want to forget previous/next queries, you can use M-x mu4e-headers-forget-queries.
It can be useful to narrow existing search results, that is, to add some clauses to the current query to match fewer messages.
For example, suppose you’re looking at some mailing list, perhaps by jumping to a maildir (M-x mu4e-headers-jump-to-maildir, j) or because you followed some bookmark (M-x mu4e-headers-search-bookmark, b). Now, you want to narrow things down to only those messages that have attachments.
This is when M-x mu4e-headers-search-narrow (/) comes in handy. It asks for an additional search pattern, which is appended to the current search query, in effect getting you the subset of the currently shown headers that also match this extra search pattern. \ takes you back to the previous query, so, effectively ‘widens’ the search. Technically, narrowing the results of query x with expression y implies doing a search (x) AND (y).
Note that messages that were not in your original search results because
mu4e-headers-results-limit may show up in the narrowed query.
It can be useful to not only show the messages that directly match a certain
query, but also include messages that are related to these messages. That is,
messages that belong to the same discussion threads are included in the
results, just like e.g. Gmail does it. You can enable this behavior by setting
t, and you can toggle between
including/not-including with W.
Be careful though when e.g. deleting ranges of messages from a certain folder — the list may now also include messages from other folders.
Another useful feature is skipping of duplicate messages. When you have
copies of messages, there’s usually little value in including more than one in
search results. A common reason for having multiple copies of messages is the
combination of Gmail and offlineimap, since that is the way the labels /
virtual folders in Gmail are represented. You can enable skipping duplicates
t, and you can toggle
between the skipping/not skipping with V.
Note, messages are considered duplicates when they have the same Message-Id.