summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2016-09-26debian: update symbols for 0.23debian/0.23_rc0-10.23_rc0David Bremner
New sub-APIs: config, built_with, message_property. A new exception used internally. Mark the exception as optional, as it only shows up when built against Xapian supporting FieldProcessors
2016-09-26debian: changelog stanza for 0.23~rc0-1David Bremner
2016-09-26version: bump to 0.23~rc0David Bremner
2016-09-25emacs: tag deleted face bugfixMark Walters
Commit d25d33ff cleaned up some of the tag face code. However, for the face notmuch-tag-deleted it used the test ((class color) (supports :strike-through)) to decide whether to use red strikethrough or inverse-video (emacs in a terminal typically doesn't support red strikethrough, but in X it does). However, it seems that test often returns true even though red strikethrough is not supported. This breaks the tag update code -- the wrong thing is displayed to the user. Thus we make the test explicitly more specific, changing the test to ((class color) (supports :strike-through "red"))
2016-09-24test: test-lib.sh: use $BASH instead of ${SHELL-sh} to relaunchTomi Ollila
In case of the test script is to be relaunced under valgrind, or --tee is requested, use the $BASH shell variable to locate the command interpreter. The $SHELL variable is re-set by non-interactive shells so in case the shell uses some other shell (e.g. zsh) for interactive use these bash scripts continue to work.
2016-09-24lib: add talloc reference from string map iterator to mapDavid Bremner
This is needed so that when the map is modified during traversal, and thus unlinked by the database code, the map is not disposed of until the iterator is done with it.
2016-09-24emacs: tree: make jump close message paneMark Walters
j is in the global notmuch keymap bound to notmuch jump. In tree-mode it makes sense to close the message pane first (otherwise the new search runs in the small top pane of tree-mode).
2016-09-24test/emacs: add broken test for message replying to msg to selfDavid Bremner
This is a strange corner case where the removing of the user's address from the To: header does the wrong thing. If we think it is worth (eventually) fixing, this test can serve as a reminder.
2016-09-23NEWS: fix markup of CONSTANTS_WITH_UNDERSCORESDavid Bremner
Alas, I did not notice when when I originally applied the NEWS patch
2016-09-23NEWS: news for Xapian 1.4 enabled featuresDavid Bremner
In fact some of these features are available in Xapian 1.3.x development releases, but these are not really widely packaged. In any case, the experts who are using development releases of Xapian can figure that out.
2016-09-22test: fix printf formatDavid Bremner
notmuch_status_t is an integer type, printing it as a string is a very bad idea.
2016-09-21build system: choose gnu99 as a C standardDavid Bremner
Apparently pre 5.1 gcc defaulted to gnu89, but we decided it was ok to use some c99 features. '-std=c99' by itself is not enough for notmuch to compile. '-std=gnu99' seems to work with clang and gcc, so I'm not convinced configuration support is needed.
2016-09-21add property: query prefix to search for specific propertiesDaniel Kahn Gillmor
We want to be able to query the properties directly, like: notmuch count property:foo=bar which should return a count of messages where the property with key "foo" has value equal to "bar".
2016-09-21cli: optionally restore message properties from dump fileDavid Bremner
This somewhat mimics the config line parsing, except there can be arbitrarily many key value pairs, so one more level of looping is required.
2016-09-21CLI: add properties to dump outputDavid Bremner
Part of providing extensibility via properties is to make sure that user data is not lost. Thus we need to be able to dump and restore properties.
2016-09-21CLI: refactor dumping of tags.David Bremner
This is mainly code movement, to make room in the loop over messages for dumping properties.
2016-09-21lib: iterator API for message propertiesDavid Bremner
This is a thin wrapper around the string map iterator API just introduced.
2016-09-21lib: extend private string map API with iteratorsDavid Bremner
Support for prefix based iterators is perhaps overengineering, but I wanted to mimic the existing database_config API.
2016-09-21lib: basic message-property APIDavid Bremner
Initially, support get, set and removal of single key/value pair, as well as removing all properties.
2016-09-21lib: private string map (associative array) APIDavid Bremner
The choice of array implementation is deliberate, for future iterator support
2016-09-21lib: read "property" terms from messages.David Bremner
This is a first step towards providing an API to attach arbitrary (key,value) pairs to messages and retrieve all of the values for a given key.
2016-09-19test: silence the output of notmuch new mid-testJani Nikula
Fix this during test run: T470-missing-headers: Testing messages with missing headers Added 2 new messages to the database.
2016-09-18emacs: reply: remove wrong sig/enc status buttonsMark Walters
This stops the (usually incorrect) sigstatus and encstatus buttons appearing when replying in emacs, and updates the test suite to match. Overriding the status button functions is a little unusual but much less intrusive than passing an argument all the way down the call chain. It also makes it clear exactly what it does. We also hide the application/pgp-encrypted part as it can only contain "Version: 1". We do this in notmuch show, which means it also happens when replying.
2016-09-18test/crypto: test reply to encrypted message in emacsDavid Bremner
This test considers the extra output about encryption/signature status as a bug, to be fixed in the next commit
2016-09-17cli/reply: only pass gmime message to add recipients to reply messageJani Nikula
The notmuch message is no longer needed. Simplify.
2016-09-17cli/reply: pass gmime message to Reply-To: redundancy detectionJani Nikula
Use gmime message instead of notmuch message in Reply-To: redundancy detection. This allows us to easily iterate over all recipient email addresses accurately, instead of just scanning for strings in the relevant message headers. This improves the accuracy of the detection in many ways. This also makes the notmuch message parameter to get_sender() unused. This will be cleaned up in a follow-up patch to not make too many changes here at once.
2016-09-17cli/reply: do not parse Reply-To: header into internet address list twiceJani Nikula
Avoid parsing Reply-To: header into internet address list twice. Move the parsing outside of reply_to_header_is_redundant(), and pass the parsed internet address list in as parameter. This also avoids leaking the memory of one copy of the internet address list.
2016-09-17cli/reply: return internet address list from get header funcsJani Nikula
Pass in GMimeMessage to simplify To/Cc/Bcc headers. We'll eventually remove the notmuch message passing altogether, but keep both for now to not make too big changes at once. Getting the headers from GMimeMessage using GMime functions fixes the error on duplicate Cc headers reported by Daniel Kahn Gillmor <dkg@fifthhorseman.net> in id:87d1ngv95p.fsf@alice.fifthhorseman.net. Get rid of an intermediate function. The small annoyance is the ownership differences in the address lists.
2016-09-17cli/reply: check for NULL list first in scan_address_list()Jani Nikula
Support passing NULL list later on. Also use it to simplify the recursion.
2016-09-17cli/reply: use dedicated functions for reply to mappingJani Nikula
The main motivation here is to move the special casing around reply-to/from handling into a function of its own, clarifying the main logic.
2016-09-17cli/reply: reduce the reply format abstractionsJani Nikula
Now that we've made the various reply formats quite similar to each other, there's no point in keeping the abstractions. They are now close enough to be put in one function. For now, a mime node will be uselessly created for the headers-only case, but this is insignificant, and may change in the future.
2016-09-17cli/reply: reuse create_reply_message() also for headers-only formatJani Nikula
Add an option for "limited" headers for the (slightly misleadingly named) headers-only format. There should be no functional changes.
2016-09-17cli/reply: make references header creation easier to followJani Nikula
Just use strdup when original references is not available, instead of trying to cram everything into a monster asprintf. There should be no functional changes.
2016-09-17cli/reply: reorganize create_reply_message()Jani Nikula
Again, in preparation for later unification, reorganize create_reply_message() to be more similar to the headers-only format reply code in notmuch_reply_format_headers_only(). Due to "pretty" header ordering, there should be no change in output. There should be no functional changes.
2016-09-17cli/reply: unify reply format functionsJani Nikula
Prepare for further future unification by making the code similar. The only functional change is that errors in mime_node_open() also break execution in default reply format.
2016-09-17cli/reply: reuse show_reply_headers() in headers-only formatJani Nikula
Align the code with default format reply. There should be no changes in output.
2016-09-17cli/reply: push notmuch reply format abstraction lower in the stackJani Nikula
There's quite a bit of duplication, and some consequent deviation, between the various notmuch reply format code paths. Perform the query and message iteration in common code, and make the format specific functions operate on single messages. There should be no functional changes.
2016-09-17test: add known broken test for reply to message with multiple Cc headersJani Nikula
As Daniel Kahn Gillmor <dkg@fifthhorseman.net> reports in id:87d1ngv95p.fsf@alice.fifthhorseman.net, notmuch show combines multiple Cc: fields into one, while notmuch reply does not. While such messages are in violation of RFC 5322, it would be reasonable to expect notmuch to be consistent. Add a known broken test to document this expectation. This also starts a new "broken" corpus for messages which are broken. Details: The original message is formatted using the message printing in notmuch-show.c. For Cc:, it uses g_mime_message_get_recipients(), which apparently combines all Cc: fields into one internally. The addresses in the reply headers, OTOH, are based on headers queried through libnotmuch. It boils down to g_mime_object_get_header() in lib/message-file.c, which returns only the first occurence of header.
2016-09-17test: make it possible to have multiple corporaJani Nikula
We largely use the corpus under test/corpus for testing. Unfortunately, many of our tests have grown to depend on having exactly this set of messages, making it hard to add new message files for testing specific cases. We do use a lot of add_message from within the tests, but it's not possible to use that for adding broken messages, and adding several messages at once can get unwieldy. Move the basic corpus under tests/corpora/default, and make it possible to add new, independent corpora along its side. This means tons of renames with a few tweaks to add_email_corpus function in test-lib.sh to let tests specify which corpus to use.
2016-09-12clean up spellingDaniel Kahn Gillmor
2016-09-12emacs: make the remaining faces configurable.Matt Armstrong
I believe this moves all "anonymous" face specifications in notmuch code into a configurable defface.
2016-09-12emacs: implement notmuch-search-color-line with dolist.Matt Armstrong
While passing a lambda to mapc is idiomatic elisp, dolist is easier to understand, and there are a few other calls to it in this file.
2016-09-12emacs: wash: make word-wrap bound message widthMark Walters
Previously if notmuch-wash-wrap-lines-length was set then all messages would be wrapped at this value (or window-width if that is smaller). This was done regardless of the message's depth in a thread -- for example, if the n.w.w.l.l is 80 and the messages depth is 20 (so indented 20 by default) the messages text only got 60 characters of space. This commit changes that so a message always gets the full n.w.w.l.l of width regardless of its indentation (unless that goes over window-width of course).
2016-09-12emacs: show: let the user override the mime-type of an attachmentMark Walters
This allows the user to override the mime-type of a part in the show buffer. This takes the simple option of displaying the part with the specified mime-type in its own buffer (in view mode). This avoids further complicating the part handling code. Bound to ". m" (i.e., m in the part map). Then the user can either enter a mime-type (with completion to all mime types that mailcap (and thus notmuch) knows about, or press return for the default choice of text/plain.
2016-09-10emacs: use define-derived-mode for defining modes.Steven Allen
This sets up and runs all the correct hooks and reduces some redundancy.
2016-09-08Merge branch 'release'David Bremner
hand fixed conflicts with NEWS
2016-09-08NEWS: add news for 0.22.2debian/0.22.2-10.22.2David Bremner
2016-09-08debian: add changelog stanza for 0.22.2-1David Bremner
2016-09-08version: bump to 0.22.2David Bremner
2016-09-08test/crypto: hard code fingerprintDavid Bremner
Originally the intent was to make the test more robust against changing test keys. It turns out that (unscientifically) gpg --with-colons output changes more often than our test key. Rather than making the script more complex, just hard code the fingerprint. This fixes Debian bug #847013; I expect similar test failures as other distros adopt gnupg 2.1.15