]> git.cworth.org Git - notmuch-wiki/blob - software.mdwn
Add a wiki page `software`.
[notmuch-wiki] / software.mdwn
1 [[!img notmuch-logo.png alt="Notmuch logo" class="left"]]
2 # Sofware working with Maildir and Notmuch
3
4 ## <span id="formats">**Mail storage formats**</span>
5
6 Notmuch can index any mail that is stored as singular files in directory structure.
7 Here are some popular formats used.
8
9 ### <span id="maildir">**Maildir**</span>
10
11 This is the native mail storage format for notmuch.
12 In addition to indexing mail content notmuch can synchronize standard maildir flags with notmuch tags. See [[special-tags]].
13
14 [Original specification](http://cr.yp.to/proto/maildir.html), for extensions see below.
15
16 There are slight differences on how to handle the `new` subdirectory.
17 While the definition specifies it's for freshly-delivered mail before adding flags only, some software (notably mutt) use it for all unread mail even after the flags were added to filenames.
18
19 ### <span id="nntp-spool">**NNTP Spool**</span>
20
21 As NNTP uses incrementing number for each message in a newsgroup those are often used for filenames in NNTP software.
22 Notmuch can index mail stored like this, but flag synchronization is unavailable and mail-reading software that expects maildir might not work with it.
23
24 ### <span id="nntp-spool">**MH folders**</span>
25
26 This is structured very much like NNTP Spool with numbered messages in a directory.
27 Above statements apply.
28
29 ## <span id="frontends">**Notmuch frontends**</span>
30
31 Have a separate [[wiki page|frontends]].
32
33 ## <span id="synchronizers">**Mail fetchers and synchronizers**</span>
34
35 <table>
36   <thead>
37     <tr>
38       <th>Name</th>
39       <th>Bidirectional</th>
40       <th>Protocol</th>
41       <th>Keywords/tags</th>
42       <th>More info</th>
43     </th>
44   </thead>
45   <tbody>
46     <tr>
47       <td><a href="http://offlineimap.org/">offlineimap</a></td>
48       <td>yes</td>
49       <td>IMAP4</td>
50       <td>standard-only?</td>
51       <td>-</td>
52     </tr>
53     <tr>
54       <td><a href="http://www.muchsync.org/">muchsync</a></td>
55       <td>yes</td>
56       <td>custom</td>
57       <td>notmuch database</td>
58       <td>-</td>
59     </tr>
60     <tr>
61       <td><a href="http://wiki2.dovecot.org/Tools/Doveadm/Sync">dsync</a></td>
62       <td>yes</td>
63       <td>IMAP4/POP3/custom</td>
64       <td>dovecot format</td>
65       <td>
66         <ul>
67         <li><a href="http://wiki2.dovecot.org/Migration/Dsync">IMAP/POP howto</a></li>
68         <li><a href="http://wiki2.dovecot.org/Replication">replication howto<a></li>
69         </ul>
70       </td>
71     </tr>
72     <tr>
73       <td><a href="http://isync.sourceforge.net/">mbsync/isync</a></td>
74       <td>yes</td>
75       <td>IMAP4</td>
76       <td>standard-only</td>
77       <td>-</td>
78     </tr>
79     <tr>
80       <td><a href="http://pyropus.ca/software/getmail/">getmail</a></td>
81       <td>no</td>
82       <td>IMAP4/POP3</td>
83       <td>no</td>
84       <td>-</td>
85     </tr>
86     <tr>
87       <td><a href="http://fetchmail.berlios.de/">fetchmail</a></td>
88       <td>no</td>
89       <td>IMAP4/POP3</td>
90       <td>no</td>
91       <td>no maildir support, can deliver to SMTP or local MDA</td>
92     </tr>
93     <tr>
94       <td><a href="https://github.com/OfflineIMAP/imapfw">imapfw</a></td>
95       <td>yes</td>
96       <td>IMAP4</td>
97       <td>?</td>
98       <td>work in progress</td>
99     </tr>
100   </tbody>
101 </table>
102
103 Other links of interest:
104
105 * [mswatch](http://mswatch.sourceforge.net/) Triggers sync on mailbox changes.
106 * [mailsync](http://mailsync.sourceforge.net/) Based on UW library that doesn't support Maildir out of the box. MH folders are supported.
107 * [imapsync](http://imapsync.lamiral.info/) (unidirectional)
108 * [slrnpull](http://slrn.sourceforge.net/docs/slrn-FAQ-5.html) Fetches NNTP newsgroups (such as USENET or Gmane) into numbered spool format which notmuch can index.
109
110 ## <span id="mda">**Filters and mail delivery agents**</span>
111
112 * [procmail](http://www.procmail.org/)
113 * Courier (or standalone): [maildrop](http://www.courier-mta.org/maildrop/)
114 * Dovecot: [dovecot-lda](http://wiki.dovecot.org/LDA)
115 * Postfix: [local](http://www.postfix.org/local.8.html)
116 * Exim: [appendfile](http://exim.org/exim-html-current/doc/html/spec_html/ch-the_appendfile_transport.html#SECTmaildirdelivery)
117 * Qmail: [qmail-local](http://qmail.org/man/man8/qmail-local.html)
118 * OpenSMTPD: supports tuning via [.forward](https://www.opensmtpd.org/forward.5.html) files
119
120 Many MDAs also support filtering via [Sieve](https://en.wikipedia.org/wiki/Sieve_%28mail_filtering_language%29) language.
121
122 ## <span id="imap">**IMAP servers**</span>
123
124 Internet Mail Access Protocol servers that can interoperate with notmuch.
125 It is of note that IMAP protocol supports storing so-called [keywords](https://tools.ietf.org/html/rfc3501#page-11) (user-defined flags) which are mostly equivalent to notmuch tags.
126 Unfortunately Maildir does not have standard way to encode keywords, so there are extensions neccessary to store that information.
127
128 ### <span id="dovecot">**Dovecot**</span>
129
130 The fully standard-compliant IMAP server.
131 Has efficient syncing and multimaster replication capability.
132
133 * Homepage: http://dovecot.org/
134 * Maildir extensions: http://wiki.dovecot.org/MailboxFormat/Maildir
135
136 Up to 26 different keywords can be stored per-maildir using Maildir flags a-z.
137 Their meaning is defined via `dovecot-keywords` file which is simple, well-defined text file which maps each letter to specifig tag/keyword.
138 If more than 26 keywords appear in one Maildir then some of them are stored in [dovecot-specific](http://wiki.dovecot.org/Design/Indexes/MainIndex) [index files](http://wiki.dovecot.org/IndexFiles).
139 Dovecot's dsync will sync keywords into this format.
140
141 ### <span id="dovecot">**Courier**</span>
142
143 The origin of [Maildir++](http://www.courier-mta.org/imap/README.maildirquota.html) format. Ships many useful commandline tools.
144
145 Further maildir specification: http://www.courier-mta.org/maildir.html
146
147 It stores keywords in [courierimapkeywords](http://www.courier-mta.org/imap/README.imapkeywords.html) inside the maildir.
148 It supports arbitrary amount of keywords, but unfortunately actually reading them is rather convoluted process.
149
150 ### <span id="imap-other">**Other**</span>
151
152 * UW-IMAP supports MH folders and there is a patch for Maildir support.
153 * Cyrus has it's [own mailbox format](http://www.cyrusimap.org/docs/cyrus-imapd/2.5.7/internal/mailbox-format.php), but stores messages as single files which should be indexable.