| 1 |
AERC-NOTMUCH(5) |
| 2 |
|
| 3 |
# NAME |
| 4 |
|
| 5 |
aerc-notmuch - notmuch configuration for *aerc*(1) |
| 6 |
|
| 7 |
# SYNOPSIS |
| 8 |
|
| 9 |
aerc supports using the notmuch email system as a backend, for fast indexing |
| 10 |
and searching. |
| 11 |
|
| 12 |
For this to be enabled, aerc needs to be built with notmuch support. |
| 13 |
Refer to the installation instructions for details. |
| 14 |
|
| 15 |
# CONFIGURATION |
| 16 |
|
| 17 |
Basic Notmuch configuration may be done interactively with the *:new-account* |
| 18 |
command. |
| 19 |
|
| 20 |
In _accounts.conf_ (see *aerc-accounts*(5)), the following notmuch-specific |
| 21 |
options are available: |
| 22 |
|
| 23 |
*check-mail-cmd* = _<command>_ |
| 24 |
Command to run in conjunction with the *check-mail* option. It may be |
| 25 |
convenient to update notmuch's database in this command. |
| 26 |
|
| 27 |
Examples: |
| 28 |
check-mail-cmd = mbsync -a |
| 29 |
|
| 30 |
check-mail-cmd = mbsync -a && notmuch new |
| 31 |
|
| 32 |
*check-mail-timeout* = _<duration>_ |
| 33 |
Timeout for the *check-mail-cmd*. The command will be stopped if it does |
| 34 |
not complete in this interval and an error will be displayed. Increase from |
| 35 |
the default if repeated errors occur |
| 36 |
|
| 37 |
Default: _10s_ |
| 38 |
|
| 39 |
*source* = notmuch://[_<profile>_] |
| 40 |
The database path and configuration file are discovered automatically |
| 41 |
via environment variables (*NOTMUCH_CONFIG*, *NOTMUCH_DATABASE*, |
| 42 |
*NOTMUCH_PROFILE*) or XDG conventions. In most cases, the following |
| 43 |
configuration will work as expected: |
| 44 |
|
| 45 |
source = notmuch:// |
| 46 |
|
| 47 |
An optional profile name can be specified: |
| 48 |
|
| 49 |
source = notmuch://work |
| 50 |
|
| 51 |
*query-map* = _<file>_ |
| 52 |
Path to a file containing a mapping from display name to notmuch query |
| 53 |
in the form of *<NAME>*=_<QUERY>_. |
| 54 |
|
| 55 |
Multiple entries can be specified, one per line. Lines starting with _#_ |
| 56 |
are ignored and serve as comments. |
| 57 |
|
| 58 |
e.g. inbox=tag:inbox and not tag:archived |
| 59 |
|
| 60 |
*exclude-tags* = _<tag1,tag2,tag3...>_ |
| 61 |
Comma separated list of tags which will be excluded from query results, |
| 62 |
unless explicitly mentioned in the query. |
| 63 |
|
| 64 |
This can for example be useful if you use an _archive_ or _spam_ tag. |
| 65 |
|
| 66 |
*enable-maildir* = _true_|_false_ |
| 67 |
Enable maildir integration. When set to _true_, aerc will use the |
| 68 |
notmuch database's mail root to list available folders and enable |
| 69 |
commands such as *:delete* and *:archive*. |
| 70 |
|
| 71 |
N.B.: aerc will still always show messages and not files (under notmuch, |
| 72 |
a single message can be represented by several files), which makes the |
| 73 |
semantics of certain commands as *move* ambiguous. Use *multi-file-strategy* |
| 74 |
to tell aerc how to resolve these ambiguities. |
| 75 |
|
| 76 |
Default: _true_ |
| 77 |
|
| 78 |
*maildir-account-path* = _<path>_ |
| 79 |
Path to the maildir account relative to the mail root. Only used when |
| 80 |
*enable-maildir* is set to _true_. |
| 81 |
|
| 82 |
This can be used to have a single notmuch database, with a suitably |
| 83 |
prepared maildir store, usable from multiple conceptually different |
| 84 |
aerc accounts. |
| 85 |
|
| 86 |
*multi-file-strategy* = _<strategy>_ |
| 87 |
Strategy for file operations (e.g., move, copy, delete) on messages that are |
| 88 |
backed by multiple files. Possible values: |
| 89 |
|
| 90 |
- *refuse* (default): Refuse to act. |
| 91 |
- *act-all*: Act on all files. |
| 92 |
- *act-one*: Act on one of the files, arbitrarily chosen, and ignore the |
| 93 |
rest. |
| 94 |
- *act-one-delete-rest*: Like *act-one*, but delete the remaining files. |
| 95 |
- *act-dir*: Act on all files within the current folder and ignore the rest. |
| 96 |
Note that this strategy only works within the maildir directories; in other |
| 97 |
directories, it behaves like *refuse*. |
| 98 |
- *act-dir-delete-rest*: Like *act-dir*, but delete the remaining files. |
| 99 |
|
| 100 |
Note that the strategy has no effect on cross-account operations. Copying a |
| 101 |
message across accounts will always copy a single file, arbitrarily chosen. |
| 102 |
Moving a message across accounts will always copy a single file, arbitrarily |
| 103 |
chosen, and refuse to delete multiple files from the source account. |
| 104 |
|
| 105 |
# USAGE |
| 106 |
|
| 107 |
Notmuch shows slightly different behavior than for example IMAP. Some commands |
| 108 |
are slightly different in semantics and mentioned below: |
| 109 |
|
| 110 |
*cf* _<notmuch query>_ |
| 111 |
The change folder command allows for arbitrary notmuch queries. Performing a |
| 112 |
*:cf* command will perform a new top-level notmuch query. |
| 113 |
|
| 114 |
*filter* _<notmuch query>_ |
| 115 |
The filter command for notmuch backends takes in arbitrary notmuch queries. |
| 116 |
It applies the query on the set of messages shown in the message list. This |
| 117 |
can be used to perform successive filters/queries. It is equivalent to |
| 118 |
performing a set of queries concatenated with "and". |
| 119 |
|
| 120 |
# SEE ALSO |
| 121 |
|
| 122 |
*aerc*(1) *aerc-accounts*(5) *aerc-smtp*(5) *aerc-maildir*(5) |
| 123 |
|
| 124 |
# AUTHORS |
| 125 |
|
| 126 |
Originally created by Drew DeVault and maintained by Robin Jarry who is assisted |
| 127 |
by other open source contributors. For more information about aerc development, |
| 128 |
see _https://sr.ht/~rjarry/aerc/_. |