]> git.notmuchmail.org Git - notmuch/blob - TODO
Merge branch '0.3.x'
[notmuch] / TODO
1 Fix the things that are causing the most pain to new users
2 ----------------------------------------------------------
3 1. A new import is tagging all messages as "inbox" -- total pain
4
5 2. Allow an easy way to get tags from directory names (if the user has them)
6
7 Emacs interface (notmuch.el)
8 ----------------------------
9 Enhance '+' and '-' in the search view to operate on an entire region
10 if set.
11
12 Fix '*' to work by simply calling '+' or '-' on a region consisting of
13 the entire buffer.
14
15 Add a global keybinding table for notmuch, and then view-specific
16 tables that add to it.
17         
18 Add a '|' binding from the search view.
19
20 Add support for choosing from one of the user's configured email
21 addresses for the From line.
22
23 Make 'notmuch-show-pipe-message have a private history.
24
25 Add support for a delete keybinding that adds a "deleted" tag to the
26 current message/thread and make searches not return deleted messages
27 by default, (unless the user asks explicitly for deleted messags in
28 the search query).
29
30 Add support to "mute" a thread (add a "muted" tag and then don't
31 display threads in searches by default where any message of the thread
32 has the "muted" tag).
33
34 Fix i-search to open up invisible citations as necessary.
35
36 Make '=' count from the end rather than from the beginning if more
37 than half-way through the buffer.
38
39 Fix to automatically wrap long headers (for RFC compliance) before
40 sending. This should probably just be fixed in message-mode itself,
41 (but perhaps we can have a notmuch-message-mode that layers this on
42 top).
43
44 Implement Fcc and use it for all messages, (whether a new composition,
45 a reply, or a forward). This again may require a notmuch-message-mode
46 that extends message-mode.
47
48 Stop hiding the headers so much in the thread-view mode.
49
50 Allow opening a message in thread-view mode by clicking on either
51 line.
52
53 Automatically open a message when navigating to it with N or P.
54
55 Change 'a' command in thread-view mode to only archive open messages.
56
57 Add a binding to open all closed messages.
58
59 Make all authors and subjects available to isearch, (hidden by default
60 but with magic expansion while isearching).
61
62 Fix notmuch-hello as follows:
63
64         1. Change the "notmuch" and message count in the welcome sentence to
65            not be buttons.
66
67         2. Put the saved searches (if any) before the search bar.
68
69         3. When `notmuch-hello' (or even `notmuch' when it gets its new name)
70            is invoked directly, move to the first button, (go to point-min and
71            then call widget-forward). That is, if the user has any saved
72            searches, then point will be on the first one. If the user has no
73            saved searches, then point will be on the search bar.
74
75         4. Fix refresh of notmuch-hello to leave point in the same logical
76            place, (the same saved-search widget at least).
77
78 Emacs saved-search interface
79 ----------------------------
80 Here's a proposal Carl wrote (id:87einafy4u.fsf@yoom.home.cworth.org):
81
82   So what I'm imagining for the default notmuch view is something like
83   this:
84
85           Welcome to notmuch.
86
87               Notmuch search: _________________________________________
88
89           Saved searches:
90
91               55,342      All messages
92                   22      Inbox
93
94           Recent searches:
95
96                    1      from:"someone special" and tag:unread
97                   34      tag:notmuch and tag:todo
98
99           Click (or press Enter) on any search to see the results.
100           Right-click (or press Space) on any recent search to save it.
101
102   So the "saved searches" portion of the view is basically just what
103   notmuch-folder displays now. Above that there's an obvious place to
104   start a new search, (in a slightly more "web-browser-like" way than the
105   typical mini-buffer approach).
106
107   All recent searches appear in the list at the bottom automatically, and
108   there's the documented mechanism for saving a search, (giving it a name
109   and having it appear above).
110
111 Portability
112 -----------
113 Fix configure script to test each compiler warning we want to use.
114
115 Completion
116 ----------
117 Fix bash completion to complete multiple search options (both --first
118 and *then* --max-threads), and also complete value for --sort=
119 (oldest-first or newest-first).
120
121 notmuch command-line tool
122 -------------------------
123 Fix the --format=json option to not imply --entire-thread.
124
125 Implement "notmuch search --exclude-threads=<search-terms>" to allow
126 for excluding muted threads, (and any other negative, thread-based
127 filtering that the user wants to do).
128
129 Fix "notmuch show" so that the UI doesn't fail to show a thread that
130 is visible in a search buffer, but happens to no longer match the
131 current search. (Perhaps add a --matching=<secondary-search-terms>
132 option (or similar) to "notmuch show".) For now, this is being worked
133 around in the emacs interface by noticing that "notmuch show" returns
134 nothing and re-rerunning the command without the extra arguments.
135
136 Teach "notmuch search" to return many different kinds of results. Some
137 ideas:
138
139         notmuch search --output=threads # Default if no --output is given
140         notmuch search --output=messages
141         notmuch search --output=tags
142         notmuch search --output=addresses
143         notmuch search --output=terms
144
145 Add a "--format" option to "notmuch search", (something printf-like
146 for selecting what gets printed).
147
148 Add a "--count-only" (or so?) option to "notmuch search" for returning
149 the count of search results.
150
151 Give "notmuch restore" some progress indicator.
152
153 Fix "notmuch restore" to operate in a single pass much like "notmuch
154 dump" does, rather than doing N searches into the database, each
155 matching 1/N messages.
156
157 Add a "-f <filename>" option to select an alternate configuration
158 file.
159
160 Allow configuration for filename patterns that should be ignored when
161 indexing.
162
163 Replace the "notmuch part --part=id" command with "notmuch show
164 --part=id", (David Edmonson wants to rewrite some of "notmuch show" to
165 provide more MIME-structure information in its output first).
166
167 Replace the "notmuch search-tags" command with "notmuch search
168 --output=tags".
169
170 Fix to avoid this ugly message:
171
172         (process:17197): gmime-CRITICAL **: g_mime_message_get_mime_part: assertion `GMIME_IS_MESSAGE (message)' failed
173         Warning: Not indexing empty mime part.
174
175   This probably means adding a test case to generate that message,
176   filing an upstream bug against GMime, and then silencing the
177   notmuch-generated portion of the warning (so that once GMime is
178   fixed, this is all silent).
179
180 Simplify notmuch-reply to simply print the headers (we have the
181 original values) rather than calling GMime (which encodes) and adding
182 the confusing gmime-filter-headers.c code (which decodes).
183
184 notmuch library
185 ---------------
186 Add an interface to accept a "key" and a byte stream, rather than a
187 filename.
188
189 Provide a sane syntax for date ranges. First, we don't want to require
190 both endpoints to be specified. For example it would be nice to be
191 able to say things like "since:2009-01-1" or "until:2009-01-1" and
192 have the other endpoint be implicit. Second we'd like to support
193 relative specifications of time such as "since:'2 months ago'". To do
194 any of this we're probably going to need to break down an write our
195 own parser for the query string rather than using Xapian's QueryParser
196 class.
197
198 Make failure to read a file (such as a permissions problem) a warning
199 rather than an error (should be similar to the existing warning for a
200 non-mail file).
201
202 Actually compile and install a libnotmuch shared library.
203
204 Fix to use the *last* Message-ID header if multiple such headers are
205 encountered, (I noticed this is one thing that kept me from seeing the
206 same message-ID values as sup).
207
208 Add support for configuring "virtual tags" which are a tuple of
209 (tag-name, search-specification). The database is responsible for
210 ensuring that the virtual tag is always consistent.
211
212 Indicate to the user if two files with the same message ID have
213 content that is actually different in some interesting way. Perhaps
214 notmuch initially sees all changes as interesting, and quickly learns
215 from the user which changes are not interesting (such as the very
216 common mailing-list footer).
217
218 Fix notmuch_query_count_messages to share code with
219 notmuch_query_search_messages rather than duplicating code. (And
220 consider renaming it as well.)
221
222 Provide a mechanism for doing automatic address completion based on
223 notmuch searches. Here was one proposal made in IRC:
224
225         <cworth> I guess all it would really have to be would be a way
226                  to configure a series of searches to try in turn,
227                  (presenting ambiguities at a given single level, and
228                  advancing to the next level only if one level
229                  returned no matches).
230         <cworth> So then I might have a series that looks like this:
231         <cworth> notmuch search --output=address_from tag:address_book_alias
232         <cworth> notmuch search --output=address_to tag:sent
233         <cworth> notmuch search --output=address_from
234         <cworth> I think I might like that quite a bit.
235         <cworth> And then we have a story for an address book for
236                  non-emacs users.
237
238 Provide a ~me Xapian synonym for all of the user's configured email
239 addresses.
240
241 Add symbol hiding so that we don't risk leaking any private symbols
242 into the shared-library interface.
243
244 Audit all libnotmuch entry points to ensure that all Xapian calls are
245 wrapped in a try/catch block.
246
247 Search syntax
248 -------------
249 Implement support for "tag:*" to expand to all tags.
250
251 Fix "notmuch search to:" to be less confusing. Many users expect this
252 to search for all messages with a To: header, but it instead searches
253 for all messages with the word "to". If we don't provide the first
254 behavior, perhaps we should exit on an error when a configured prefix
255 is provided with no value?
256
257 Support "*" in all cases and not just as a special case. That is, "* "
258 should also work, as well as "* and tag:inbox".
259
260 Implement a syntax for requesting set-theoertic operations on results
261 of multiple searches. For example, I would like to do:
262
263         "tag:inbox" SET-SUBTRACT "tag:muted"
264
265     as well as:
266
267         "tag:notmuch and <date-range>" SET-INTERSECT
268         "tag:notmuch and not (tag:merged or tag:postponed)"
269
270     See id:3wdpr282yz2.fsf@testarossa.amd.com for more details on the
271     use cases of the above.
272
273 Database changes
274 ----------------
275 Store a reference term for every message-id that appears in
276 References. We just started doing this for newly-added documents, but
277 at the next convenient database-schema upgrade, we should go back and
278 fix old messages to be consistent.
279
280 Start indexing the List-Id header, (and re-index this header for
281 existing messages at the next database upgrade).
282
283 Start indexing the message file's directory ana make it available for
284 search as "folder:" (and re-index this value for existing messages at
285 the next database upgrade).
286
287 Add support for the user to specify custom headers to be indexed (and
288 re-index these for existing messages at the next database upgrade).
289
290 Test suite
291 ----------
292 Start testing --format=json.
293
294 Achieve 100% test coverage with the test suite.
295
296 Modularize test suite (to be able to run individual tests).
297
298 Summarize test results at the end.
299
300 Fix the insane quoting nightmare of the test suite, (and once we do
301 that we can actually test the implicit-phrase search feature such as
302 "notmuch search 'body search (phrase)'"
303
304 Test "notmuch reply" choosing the correct email address from the
305 Received header when no configured email address appears in To or Cc.
306
307 General
308 -------
309 Audit everything for dealing with out-of-memory (and drop xutil.c).
310
311 Investigate why the notmuch database is slightly larger than the sup
312 database for the same corpus of email.