[PATCH v2] nmbug-status: add support for specifying sort order for each view

2015-09-26 Thread Jani Nikula
Let each view have a "sort" key, typically used with values "oldest-first" or "newest-first" (although all values in Query.SORT are accepted), and sort the results accordingly. Oldest first remains the default. The dynamic approach of mapping sort values is as suggested by W. Trevor King

[PATCH 2/2] cli: content disposition values are not case-sensitive

2015-09-26 Thread Jani Nikula
Per RFC 2183, the values for Content-Disposition values are not case-sensitive. While at it, use the gmime function for getting at the disposition string instead of referencing the field directly. This fixes attachment display and quoting in notmuch show and reply, respectively. ---

Re: [PATCH 6/8] cli: crypto: S/MIME verification support

2015-09-26 Thread Jani Nikula
On Sun, 16 Aug 2015, David Bremner wrote: > From: Jani Nikula > > notmuch-show --verify will now also process S/MIME multiparts if > encountered. Requires gmime-2.6 and gpgsm. > > Based on work by Jameson Graef Rollins . > --- >

Re: [bug] notmuch requires Content-Disposition mime header value to be lower case

2015-09-26 Thread Jani Nikula
On Fri, 18 Sep 2015, David Bremner wrote: > Johannes Schauer writes: > >> Hi, >> >> Quoting David Bremner (2015-09-18 14:03:20) >>> I'd recommend making your own new test, rather than modifying existing >>> ones to test multiple things. I'd also recommend

Re: expose notmuch_database_new to libraries?

2015-09-26 Thread Jani Nikula
On Sat, 26 Sep 2015, "Wael M. Nasreddine" wrote: > I have a use case where I'd like to call 'notmuch new' > programmatically via the bindings (custom Go bindings). Is it at all > possible to expose notmuch_new_command[0] through lib/notmuch.h? The > logic of

[PATCH 1/2] lib: content disposition values are not case-sensitive

2015-09-26 Thread Jani Nikula
Per RFC 2183, the values for Content-Disposition values are not case-sensitive. While at it, use the gmime function for getting at the disposition string instead of referencing the field directly. This fixes "attachment" tagging and filename term generation for attachments while indexing. ---

[PATCH] completion: handle notmuch address --deduplicate= option

2015-09-26 Thread Jani Nikula
Complete notmuch address --deduplicate=(no|mailbox|address). --- completion/notmuch-completion.bash | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/completion/notmuch-completion.bash b/completion/notmuch-completion.bash index 960275d1f672..68b069013655 100644 ---

Re: [PATCH v2 0/9] cli: alternative address deduplication

2015-09-26 Thread David Bremner
David Bremner writes: > Jani Nikula writes: > >> This is v2 of id:cover.1440859765.git.j...@nikula.org addressing review >> from the first (or rfc) version. Test are still missing, but everything >> else should be in place. (At least patches 1, 2, and 5 could

Re: [PATCH] lib: add support for date:..! to mean date:..

2015-09-26 Thread Tomi Ollila
On Sat, Sep 26 2015, David Bremner wrote: > Jani Nikula writes: > >> It doesn't seem likely we can support simple date: expanding to >> date:.. any time soon. (This can be done with a future >> version of Xapian, or with a custom query query parser.) In the

Re: [PATCH 8/8] debian: add gpgsm as build dependency

2015-09-26 Thread Daniel Kahn Gillmor
On Sun 2015-08-16 13:41:16 -0400, David Bremner wrote: > It's not needed for the actual build, but it is needed to run > the SMIME tests. > --- > debian/control | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/debian/control b/debian/control > index 05cd04f..37ecedd 100644 > ---

[Patch v3 2/4] lib: add versions of n_q_count_{message, threads} with status return

2015-09-26 Thread David Bremner
Although I think it's a pretty bad idea to continue using the old API, this allows both a more gentle transition for clients of the library, and allows us to break one monolithic change into a series --- lib/database.cc | 8 +++- lib/notmuch.h | 52

[patch v3.1] cli: update to use new count API

2015-09-26 Thread David Bremner
Essentially replace each call to notmuch_count_* with the corresponding _st call, followed by print_status_query. --- notmuch-count.c | 12 ++-- notmuch-reply.c | 7 ++- notmuch-search.c | 16 ++-- notmuch-show.c | 7 ++- 4 files changed, 36 insertions(+), 6

[Patch v3 4/4] ruby: use new count API

2015-09-26 Thread David Bremner
This change of replacing ignoring errors with exceptions is intended, and indeed one of the main motivations for the libnotmuch API changes. --- bindings/ruby/query.c | 24 ++-- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/bindings/ruby/query.c

[Patch v3 3/4] cli: update to use new count API

2015-09-26 Thread David Bremner
Essentially replace each call to notmuch_count_* with the corresponding _st call, followed by print_status_query. --- notmuch-count.c | 12 ++-- notmuch-reply.c | 7 ++- notmuch-search.c | 16 ++-- notmuch-show.c | 7 ++- 4 files changed, 36 insertions(+), 6

[Patch v3 1/4] cli/count: simplify and document return value of print_count

2015-09-26 Thread David Bremner
Essentially a cosmetic change. --- notmuch-count.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/notmuch-count.c b/notmuch-count.c index 09613e6..be3e236 100644 --- a/notmuch-count.c +++ b/notmuch-count.c @@ -67,6 +67,7 @@ count_files (notmuch_query_t *query) return

[PATCH] python: update bindings for new count API

2015-09-26 Thread David Bremner
Note that any mismatches are not detected until runtime (if at all) with the python bindings, so tests are crucial --- bindings/python/notmuch/query.py | 24 1 file changed, 16 insertions(+), 8 deletions(-) diff --git a/bindings/python/notmuch/query.py