]> git.notmuchmail.org Git - notmuch/blob - TODO
Merge bugfix for test-suite correctness.
[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 Emacs saved-search interface
49 ----------------------------
50 Here's a proposal Carl wrote (id:87einafy4u.fsf@yoom.home.cworth.org):
51
52   So what I'm imagining for the default notmuch view is something like
53   this:
54
55           Welcome to notmuch.
56
57               Notmuch search: _________________________________________
58
59           Saved searches:
60
61               55,342      All messages
62                   22      Inbox
63
64           Recent searches:
65
66                    1      from:"someone special" and tag:unread
67                   34      tag:notmuch and tag:todo
68
69           Click (or press Enter) on any search to see the results.
70           Right-click (or press Space) on any recent search to save it.
71
72   So the "saved searches" portion of the view is basically just what
73   notmuch-folder displays now. Above that there's an obvious place to
74   start a new search, (in a slightly more "web-browser-like" way than the
75   typical mini-buffer approach).
76
77   All recent searches appear in the list at the bottom automatically, and
78   there's the documented mechanism for saving a search, (giving it a name
79   and having it appear above).
80
81 Portability
82 -----------
83 Fix configure script to test each compiler warning we want to use.
84
85 Completion
86 ----------
87 Fix bash completion to complete multiple search options (both --first
88 and *then* --max-threads), and also complete value for --sort=
89 (oldest-first or newest-first).
90
91 notmuch command-line tool
92 -------------------------
93 Fix the --format=json option to not imply --entire-thread.
94
95 Implement "notmuch search --exclude-threads=<search-terms>" to allow
96 for excluding muted threads, (and any other negative, thread-based
97 filtering that the user wants to do).
98
99 Fix "notmuch show" so that the UI doesn't fail to show a thread that
100 is visible in a search buffer, but happens to no longer match the
101 current search. (Perhaps add a --matching=<secondary-search-terms>
102 option (or similar) to "notmuch show".) For now, this is being worked
103 around in the emacs interface by noticing that "notmuch show" returns
104 nothing and re-rerunning the command without the extra arguments.
105
106 Teach "notmuch search" to return many different kinds of results. Some
107 ideas:
108
109         notmuch search --output=threads # Default if no --output is given
110         notmuch search --output=messages
111         notmuch search --output=tags
112         notmuch search --output=addresses
113         notmuch search --output=terms
114
115 Add a "--format" option to "notmuch search", (something printf-like
116 for selecting what gets printed).
117
118 Add a "--count-only" (or so?) option to "notmuch search" for returning
119 the count of search results.
120
121 Give "notmuch restore" some progress indicator.
122
123 Fix "notmuch restore" to operate in a single pass much like "notmuch
124 dump" does, rather than doing N searches into the database, each
125 matching 1/N messages.
126
127 Add a "-f <filename>" option to select an alternate configuration
128 file.
129
130 Allow configuration for filename patterns that should be ignored when
131 indexing.
132
133 Replace the "notmuch part --part=id" command with "notmuch show
134 --part=id", (David Edmonson wants to rewrite some of "notmuch show" to
135 provide more MIME-structure information in its output first).
136
137 Replace the "notmuch search-tags" command with "notmuch search
138 --output=tags".
139
140 Fix to avoid this ugly message:
141
142         (process:17197): gmime-CRITICAL **: g_mime_message_get_mime_part: assertion `GMIME_IS_MESSAGE (message)' failed
143         Warning: Not indexing empty mime part.
144
145   This probably means adding a test case to generate that message,
146   filing an upstream bug against GMime, and then silencing the
147   notmuch-generated portion of the warning (so that once GMime is
148   fixed, this is all silent).
149
150 Simplify notmuch-reply to simply print the headers (we have the
151 original values) rather than calling GMime (which encodes) and adding
152 the confusing gmime-filter-headers.c code (which decodes).
153
154 notmuch library
155 ---------------
156 Add an interface to accept a "key" and a byte stream, rather than a
157 filename.
158
159 Provide a sane syntax for date ranges. First, we don't want to require
160 both endpoints to be specified. For example it would be nice to be
161 able to say things like "since:2009-01-1" or "until:2009-01-1" and
162 have the other endpoint be implicit. Second we'd like to support
163 relative specifications of time such as "since:'2 months ago'". To do
164 any of this we're probably going to need to break down an write our
165 own parser for the query string rather than using Xapian's QueryParser
166 class.
167
168 Make failure to read a file (such as a permissions problem) a warning
169 rather than an error (should be similar to the existing warning for a
170 non-mail file).
171
172 Actually compile and install a libnotmuch shared library.
173
174 Fix to use the *last* Message-ID header if multiple such headers are
175 encountered, (I noticed this is one thing that kept me from seeing the
176 same message-ID values as sup).
177
178 Add support for configuring "virtual tags" which are a tuple of
179 (tag-name, search-specification). The database is responsible for
180 ensuring that the virtual tag is always consistent.
181
182 Indicate to the user if two files with the same message ID have
183 content that is actually different in some interesting way. Perhaps
184 notmuch initially sees all changes as interesting, and quickly learns
185 from the user which changes are not interesting (such as the very
186 common mailing-list footer).
187
188 Fix notmuch_query_count_messages to share code with
189 notmuch_query_search_messages rather than duplicating code. (And
190 consider renaming it as well.)
191
192 Provide a mechanism for doing automatic address completion based on
193 notmuch searches. Here was one proposal made in IRC:
194
195         <cworth> I guess all it would really have to be would be a way
196                  to configure a series of searches to try in turn,
197                  (presenting ambiguities at a given single level, and
198                  advancing to the next level only if one level
199                  returned no matches).
200         <cworth> So then I might have a series that looks like this:
201         <cworth> notmuch search --output=address_from tag:address_book_alias
202         <cworth> notmuch search --output=address_to tag:sent
203         <cworth> notmuch search --output=address_from
204         <cworth> I think I might like that quite a bit.
205         <cworth> And then we have a story for an address book for
206                  non-emacs users.
207
208 Provide a ~me Xapian synonym for all of the user's configured email
209 addresses.
210
211 Database changes
212 ----------------
213 Store a reference term for every message-id that appears in
214 References. We just started doing this for newly-added documents, but
215 at the next convenient database-schema upgrade, we should go back and
216 fix old messages to be consistent.
217
218 Start indexing the List-Id header, (and re-index this header for
219 existing messages at the next database upgrade).
220
221 Start indexing the message file's directory ana make it available for
222 search as "folder:" (and re-index this value for existing messages at
223 the next database upgrade).
224
225 Add support for the user to specify custom headers to be indexed (and
226 re-index these for existing messages at the next database upgrade).
227
228 Test suite
229 ----------
230 Start testing --format=json.
231
232 Achieve 100% test coverage with the test suite.
233
234 Modularize test suite (to be able to run individual tests).
235
236 Summarize test results at the end.
237
238 Fix the insane quoting nightmare of the test suite, (and once we do
239 that we can actually test the implicit-phrase search feature such as
240 "notmuch search 'body search (phrase)'"
241
242 Test "notmuch reply" choosing the correct email address from the
243 Received header when no configured email address appears in To or Cc.
244
245 General
246 -------
247 Audit everything for dealing with out-of-memory (and drop xutil.c).
248
249 Investigate why the notmuch database is slightly larger than the sup
250 database for the same corpus of email.