Re: v2 of valgrind based memory tests

2012-12-25 Thread Austin Clements
On Mon, 24 Dec 2012, da...@tethera.net wrote: These obsolete id:1355196820-29734-1-git-send-email-da...@tethera.net I tried to follow the suggestions of id:20121216191121.gh6...@mit.edu pretty closely. LGTM. In the long run, I wonder if we want to separate the time and

Re: [PATCH] NEWS for emacs part visibility change

2012-12-25 Thread Austin Clements
On Sun, 23 Dec 2012, Mark Walters markwalters1...@gmail.com wrote: --- Here is some news for the recent part visibility change. I am not completely happy with the wording so please do read. In particular should it mention how the user's preferred part is chosen

Re: [PATCH] emacs: show: make id links respect window

2012-12-25 Thread Mark Walters
On Mon, 24 Dec 2012, David Bremner da...@tethera.net wrote: Mark Walters markwalters1...@gmail.com writes: I think this is a bug but that could be debated. It is particularly easy to trigger with notmuch pick because that uses the split pane while focus usually remains in the `pick' pane

[PATCH] NEWS for emacs part visibility change

2012-12-25 Thread Mark Walters
Wording suggested by Austin. --- I have taken Austin's (excellent) wording and agree with the downplaying of notmuch-show-all-multipart/alternative-parts. Best wishes Mark NEWS | 11 +++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/NEWS b/NEWS index

[PATCH] contrib: pick: close message pane when quitting from show in the message pane

2012-12-25 Thread Mark Walters
We add a hook to the show buffer in the message window to close the message window when that buffer quits. It checks that the message-window is still displaying the show-message buffer and then closes it. --- This is just a slightly tidier version of the previous patch. It is more natural to

Re: [PATCH] contrib: pick: close message pane when quitting from show in the message pane

2012-12-25 Thread Tomi Ollila
On Tue, Dec 25 2012, Mark Walters markwalters1...@gmail.com wrote: We add a hook to the show buffer in the message window to close the message window when that buffer quits. It checks that the message-window is still displaying the show-message buffer and then closes it. --- This is just a

Re: [PATCH 1/5] util: Factor out boolean term quoting routine

2012-12-25 Thread David Bremner
Austin Clements amdra...@mit.edu writes: This could live in tag-util as well, but it is really nothing specific to tags (although the conventions are specific to Xapian). Furthermore, this now combines the term prefix with the quoted term; arguably this is just as easy to do in the caller,

Re: v2 of valgrind based memory tests

2012-12-25 Thread David Bremner
Austin Clements amdra...@mit.edu writes: On Mon, 24 Dec 2012, da...@tethera.net wrote: LGTM. In the long run, I wonder if we want to separate the time and memory tests like this or if some tests would make sense in either mode. pushed. At the moment, the split into time versus memory tests

Re: [PATCH 2/5] util: Function to parse boolean term queries

2012-12-25 Thread David Bremner
Austin Clements amdra...@mit.edu writes: +if (consume_double_quote (pos)) { + char *out = talloc_strdup (ctx, pos); + pos = *term_out = out; + while (1) { Overall the control flow here is a bit tricky to follow. I'm not sure if a real loop condition would help or make it

Re: [PATCH 3/5] dump: Disallow \n in message IDs

2012-12-25 Thread David Bremner
Austin Clements amdra...@mit.edu writes: randomchar = random_unichar (); + if (randomchar == '\n') + randomchar = 'x'; what about something like do { randomchar = random_unichar (); } while (randomchar == '\n'); ___

Re: [PATCH 2/5] util: Function to parse boolean term queries

2012-12-25 Thread David Bremner
David Bremner da...@tethera.net writes: So if there is no quote, we skip the part after the ':'? I guess I probably missed something because that doesn't sound like the intended behaviour. Indeed the following addition to the test shows it works fine in context. So I guess I just don't follow

Re: [PATCH 5/5] man: Update notmuch-dump(1) for new batch-tag format

2012-12-25 Thread David Bremner
Overall I agree this is conceptually cleaner. Transforming between quoting formats is inherently delicate; I suspect there will always be at least one special case missed. I did find the dequoting code a bit baffling, but this is more of an implementation issue. There is a certain cognitive

Re: [PATCH 5/5] man: Update notmuch-dump(1) for new batch-tag format

2012-12-25 Thread David Bremner
David Bremner da...@tethera.net writes: There is a certain cognitive dissonance in using hex-quoting for tags and xapian-quoting for message-ids. Did you think about the implications of using xapian quoting for tags as well? At risk of talking to myself, I guess one loses the space

Re: [PATCH 5/5] man: Update notmuch-dump(1) for new batch-tag format

2012-12-25 Thread David Bremner
Austin Clements amdra...@mit.edu writes: --- man/man1/notmuch-dump.1 | 11 +++ 1 file changed, 7 insertions(+), 4 deletions(-) I guess the short description in notmuch-restore.1 needs updating as well. ___ notmuch mailing list

Xapian-quoting based batch-tagging.

2012-12-25 Thread david
This is an alternative version of id:1356313183-9266-1-git-send-email-da...@tethera.net batch tagging patches rebased on top of id:1356415076-5692-1-git-send-email-amdra...@mit.edu This mainly consisted of removing [Patch v9 04/17] notmuch-tag: factor out double quoting

[PATCH 01/11] parse_tag_line: use enum for return value.

2012-12-25 Thread david
From: David Bremner brem...@debian.org This is essentially cosmetic, since success=0 is promised by the comments in tag-utils.h. --- tag-util.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tag-util.c b/tag-util.c index e4e5dda..ca12b3b 100644 --- a/tag-util.c +++

[PATCH 03/11] notmuch-tag.c: convert to use tag-utils

2012-12-25 Thread david
From: David Bremner brem...@debian.org Command line parsing is factored out into a function parse_tag_command_line in tag-utils.c. There is some duplicated code eliminated in tag_query, and a bunch of translation from using the bare tag_op structs to using that tag-utils API. --- notmuch-tag.c

[PATCH 02/11] tag-util: factor out rules for illegal tags, use in parse_tag_line

2012-12-25 Thread david
From: David Bremner brem...@debian.org This will allow us to be consistent between batch tagging and command line tagging as far as what is an illegal tag. --- tag-util.c | 36 +++- 1 file changed, 31 insertions(+), 5 deletions(-) diff --git a/tag-util.c

[PATCH 05/11] test/tagging: add test for error messages of tag --batch

2012-12-25 Thread david
From: David Bremner brem...@debian.org This is based on the similar test for notmuch restore, but the parser in batch tagging mode is less tolerant of a few cases, in particular those tested by illegal_tag. --- test/tagging | 35 +++ 1 file changed, 35

[PATCH 08/11] test/tagging: add test for exotic message-ids and batch tagging

2012-12-25 Thread david
From: David Bremner brem...@debian.org The (now fixed) bug that this test revealed is that unquoted message-ids with whitespace or other control characters in them are split into several tokens by the Xapian query parser. --- test/tagging | 18 ++ 1 file changed, 18

[PATCH 09/11] notmuch-tag.1: tidy synopsis formatting, reference

2012-12-25 Thread david
From: David Bremner brem...@debian.org Consistently use [...]; one less space. Use singular search-term --- man/man1/notmuch-tag.1 |7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/man/man1/notmuch-tag.1 b/man/man1/notmuch-tag.1 index 0f86582..9444aa4 100644 ---

[PATCH 04/11] cli: add support for batch tagging operations to notmuch tag

2012-12-25 Thread david
From: Jani Nikula j...@nikula.org Add support for batch tagging operations through stdin to notmuch tag. This can be enabled with the new --batch command line option to notmuch tag. The input must consist of lines of the format: +tag|-tag [...] [--] query [...] Each line is interpreted

[PATCH 06/11] test/tagging: add basic tests for batch tagging functionality

2012-12-25 Thread david
From: David Bremner brem...@debian.org This tests argument parsing, blank lines and comments, and basic hex decoding functionality. --- test/tagging | 51 +++ 1 file changed, 51 insertions(+) diff --git a/test/tagging b/test/tagging index

[PATCH 11/11] test/tagging: add test for naked punctuation in tags; compare with quoting spaces.

2012-12-25 Thread david
From: David Bremner brem...@debian.org This test also serves as documentation of the quoting requirements. The comment lines are so that it exactly matches the man page. Nothing more embarrassing than having an example in the man page fail. --- test/tagging | 25 + 1

[PATCH 10/11] man: document notmuch tag --batch, --input options

2012-12-25 Thread david
From: Jani Nikula j...@nikula.org --- man/man1/notmuch-tag.1 | 92 1 file changed, 92 insertions(+) diff --git a/man/man1/notmuch-tag.1 b/man/man1/notmuch-tag.1 index 9444aa4..3aa2fa5 100644 --- a/man/man1/notmuch-tag.1 +++

Re: [PATCH] NEWS for emacs part visibility change

2012-12-25 Thread David Bremner
Mark Walters markwalters1...@gmail.com writes: Wording suggested by Austin. --- pushed. d ___ notmuch mailing list notmuch@notmuchmail.org http://notmuchmail.org/mailman/listinfo/notmuch

Re: [PATCH] emacs: tweak error buffer handling

2012-12-25 Thread Tomi Ollila
On Sat, Dec 22 2012, Mark Walters markwalters1...@gmail.com wrote: view-mode-enter changed between emacs 23 and emacs 24: the current code makes the error buffer disappear in emacs 24 on quitting it (ie pressing q) but this just kills the buffer without closing the split window in emacs 23.

Re: [PATCH 2/5] util: Function to parse boolean term queries

2012-12-25 Thread Austin Clements
Quoth David Bremner on Dec 25 at 10:18 am: Austin Clements amdra...@mit.edu writes: +if (consume_double_quote (pos)) { + char *out = talloc_strdup (ctx, pos); + pos = *term_out = out; + while (1) { Overall the control flow here is a bit tricky to follow. I'm not sure if a

Re: [PATCH] contrib: pick: close message pane when quitting from show in the message pane

2012-12-25 Thread David Bremner
Mark Walters markwalters1...@gmail.com writes: We add a hook to the show buffer in the message window to close the message window when that buffer quits. It checks that the message-window is still displaying the show-message buffer and then closes it. pushed. d

[PATCH v2 2/5] util: Function to parse boolean term queries

2012-12-25 Thread Austin Clements
This parses the subset of Xapian's boolean term quoting rules that are used by make_boolean_term. This is provided as a generic string utility, but will be used shortly in notmuch restore to parse and optimize for ID queries. --- util/string-util.c | 51

[PATCH v2 5/5] man: Update notmuch-dump(1) and notmuch-restore(1)

2012-12-25 Thread Austin Clements
Describe the new batch-tag format. For notmuch-restore, rather than half-heartedly duplicating the description, we now cite notmuch-dump. --- man/man1/notmuch-dump.1| 11 +++ man/man1/notmuch-restore.1 |6 ++ 2 files changed, 9 insertions(+), 8 deletions(-) diff --git

[PATCH v2 1/5] util: Factor out boolean term quoting routine

2012-12-25 Thread Austin Clements
From: Austin Clements amdra...@mit.edu This is now a generic boolean term quoting function. It performs minimal quoting to produce user-friendly queries. This could live in tag-util as well, but it is really nothing specific to tags (although the conventions are specific to Xapian). The API is

[PATCH v2 0/5] Use Xapian query syntax for batch-tag dump/restore

2012-12-25 Thread Austin Clements
This obsoletes id:1356415076-5692-1-git-send-email-amdra...@mit.edu In addition to incorporating all of David's suggestions, this reworks the boolean term parsing so it only handles the subset of quoting syntax used by make_boolean_term (which also happens to be all that we described in the

[PATCH v2 4/5] dump/restore: Use Xapian queries for batch-tag format

2012-12-25 Thread Austin Clements
This switches the new batch-tag format away from using a home-grown hex-encoding scheme for message IDs in the dump to simply using Xapian queries with Xapian quoting syntax. This has a variety of advantages beyond presenting a cleaner and more consistent interface. Foremost is that it will

[PATCH 0/5] Use Xapian query syntax for batch-tag dump/restore

2012-12-25 Thread Austin Clements
This is a stab at tweaking the new batch-tag dump/restore format to be more amenable to batch tagging. Currently, the "query" part of each line isn't really a Xapian query; it's a hex-encoded message ID prefixed with "id:". This is fine for the very limited case of dump/restore, but it extends

[PATCH 3/5] dump: Disallow \n in message IDs

2012-12-25 Thread Austin Clements
When we switch to using regular Xapian queries in the dump format, \n will cause problems, so we disallow it. Specially, while Xapian can quote and parse queries containing \n without difficultly, quoted queries containing \n still span multiple lines, which breaks the line-orientedness of the

[PATCH 5/5] man: Update notmuch-dump(1) for new batch-tag format

2012-12-25 Thread Austin Clements
--- man/man1/notmuch-dump.1 | 11 +++ 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/man/man1/notmuch-dump.1 b/man/man1/notmuch-dump.1 index 770b00f..7bd6def 100644 --- a/man/man1/notmuch-dump.1 +++ b/man/man1/notmuch-dump.1 @@ -64,13 +64,16 @@ and tags containing

[PATCH 2/5] util: Function to parse boolean term queries

2012-12-25 Thread Austin Clements
This reproduces Xapian's parsing rules for boolean term queries. This is provided as a generic string utility, but will be used shortly in notmuch restore to parse and optimize for ID queries. --- util/string-util.c | 63 util/string-util.h

[PATCH 4/5] dump/restore: Use Xapian queries for batch-tag format

2012-12-25 Thread Austin Clements
This switches the new batch-tag format away from using a home-grown hex-encoding scheme for message IDs in the dump to simply using Xapian queries with Xapian quoting syntax. This has a variety of advantages beyond presenting a cleaner and more consistent interface. Foremost is that it will

[PATCH 1/5] util: Factor out boolean term quoting routine

2012-12-25 Thread Austin Clements
From: Austin Clements This is now a generic boolean term quoting function. It performs minimal quoting to produce user-friendly queries. This could live in tag-util as well, but it is really nothing specific to tags (although the conventions are specific to Xapian). The API

v2 of valgrind based memory tests

2012-12-25 Thread Austin Clements
On Mon, 24 Dec 2012, david at tethera.net wrote: > These obsolete > > id:1355196820-29734-1-git-send-email-david at tethera.net > > I tried to follow the suggestions of > > id:20121216191121.GH6187 at mit.edu > > pretty closely. LGTM. In the long run, I wonder if we want to

[PATCH] NEWS for emacs part visibility change

2012-12-25 Thread Austin Clements
On Sun, 23 Dec 2012, Mark Walters wrote: > --- > Here is some news for the recent part visibility change. I am not > completely happy with the wording so please do read. In particular > should it mention how the user's preferred part is chosen > (notmuch-multipart/alternative-discouraged etc)? >

[PATCH] NEWS for emacs part visibility change

2012-12-25 Thread Mark Walters
Wording suggested by Austin. --- I have taken Austin's (excellent) wording and agree with the downplaying of notmuch-show-all-multipart/alternative-parts. Best wishes Mark NEWS | 11 +++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/NEWS b/NEWS index

[PATCH] contrib: pick: close message pane when quitting from show in the message pane

2012-12-25 Thread Mark Walters
We add a hook to the show buffer in the message window to close the message window when that buffer quits. It checks that the message-window is still displaying the show-message buffer and then closes it. --- This is just a slightly tidier version of the previous patch. It is more natural to

[PATCH] contrib: pick: close message pane when quitting from show in the message pane

2012-12-25 Thread Tomi Ollila
On Tue, Dec 25 2012, Mark Walters wrote: > We add a hook to the show buffer in the message window to close the > message window when that buffer quits. It checks that the > message-window is still displaying the show-message buffer and then > closes it. > --- > This is just a slightly tidier

[PATCH 1/5] util: Factor out boolean term quoting routine

2012-12-25 Thread David Bremner
Austin Clements writes: > > This could live in tag-util as well, but it is really nothing specific > to tags (although the conventions are specific to Xapian). > > Furthermore, this now combines the term prefix with the quoted term; > arguably this is just as easy to do in the caller, but this

v2 of valgrind based memory tests

2012-12-25 Thread David Bremner
Austin Clements writes: > On Mon, 24 Dec 2012, david at tethera.net wrote: > > LGTM. In the long run, I wonder if we want to separate the time and > memory tests like this or if some tests would make sense in either mode. pushed. At the moment, the split into time versus memory tests is a

[PATCH 2/5] util: Function to parse boolean term queries

2012-12-25 Thread David Bremner
Austin Clements writes: > +if (consume_double_quote ()) { > + char *out = talloc_strdup (ctx, pos); > + pos = *term_out = out; > + while (1) { Overall the control flow here is a bit tricky to follow. I'm not sure if a real loop condition would help or make it worse. > +

[PATCH 3/5] dump: Disallow \n in message IDs

2012-12-25 Thread David Bremner
Austin Clements writes: > > randomchar = random_unichar (); > + if (randomchar == '\n') > + randomchar = 'x'; > what about something like do { randomchar = random_unichar (); } while (randomchar == '\n');

[PATCH 2/5] util: Function to parse boolean term queries

2012-12-25 Thread David Bremner
David Bremner writes: > > So if there is no quote, we skip the part after the ':'? I guess I > probably missed something because that doesn't sound like the intended > behaviour. Indeed the following addition to the test shows it works fine in context. So I guess I just don't follow this control

[PATCH 5/5] man: Update notmuch-dump(1) for new batch-tag format

2012-12-25 Thread David Bremner
Overall I agree this is conceptually cleaner. Transforming between quoting formats is inherently delicate; I suspect there will always be at least one special case missed. I did find the dequoting code a bit baffling, but this is more of an implementation issue. There is a certain cognitive

[PATCH 5/5] man: Update notmuch-dump(1) for new batch-tag format

2012-12-25 Thread David Bremner
David Bremner writes: > > There is a certain cognitive dissonance in using hex-quoting for tags > and xapian-quoting for message-ids. Did you think about the > implications of using xapian quoting for tags as well? > At risk of talking to myself, I guess one loses the space delimited lists of

[PATCH 5/5] man: Update notmuch-dump(1) for new batch-tag format

2012-12-25 Thread David Bremner
Austin Clements writes: > --- > man/man1/notmuch-dump.1 | 11 +++ > 1 file changed, 7 insertions(+), 4 deletions(-) > I guess the short description in notmuch-restore.1 needs updating as well.

Xapian-quoting based batch-tagging.

2012-12-25 Thread da...@tethera.net
This is an alternative version of id:1356313183-9266-1-git-send-email-david at tethera.net batch tagging patches rebased on top of id:1356415076-5692-1-git-send-email-amdragon at mit.edu This mainly consisted of removing [Patch v9 04/17] notmuch-tag: factor out double

[PATCH 01/11] parse_tag_line: use enum for return value.

2012-12-25 Thread da...@tethera.net
From: David Bremner This is essentially cosmetic, since success=0 is promised by the comments in tag-utils.h. --- tag-util.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tag-util.c b/tag-util.c index e4e5dda..ca12b3b 100644 --- a/tag-util.c +++

[PATCH 03/11] notmuch-tag.c: convert to use tag-utils

2012-12-25 Thread da...@tethera.net
From: David Bremner Command line parsing is factored out into a function parse_tag_command_line in tag-utils.c. There is some duplicated code eliminated in tag_query, and a bunch of translation from using the bare tag_op structs to using that tag-utils API. ---

[PATCH 02/11] tag-util: factor out rules for illegal tags, use in parse_tag_line

2012-12-25 Thread da...@tethera.net
From: David Bremner This will allow us to be consistent between batch tagging and command line tagging as far as what is an illegal tag. --- tag-util.c | 36 +++- 1 file changed, 31 insertions(+), 5 deletions(-) diff --git a/tag-util.c

[PATCH 05/11] test/tagging: add test for error messages of tag --batch

2012-12-25 Thread da...@tethera.net
From: David Bremner This is based on the similar test for notmuch restore, but the parser in batch tagging mode is less tolerant of a few cases, in particular those tested by illegal_tag. --- test/tagging | 35 +++ 1 file changed, 35

[PATCH 08/11] test/tagging: add test for exotic message-ids and batch tagging

2012-12-25 Thread da...@tethera.net
From: David Bremner The (now fixed) bug that this test revealed is that unquoted message-ids with whitespace or other control characters in them are split into several tokens by the Xapian query parser. --- test/tagging | 18 ++ 1 file changed, 18

[PATCH 09/11] notmuch-tag.1: tidy synopsis formatting, reference

2012-12-25 Thread da...@tethera.net
From: David Bremner Consistently use [...]; one less space. Use singular --- man/man1/notmuch-tag.1 |7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/man/man1/notmuch-tag.1 b/man/man1/notmuch-tag.1 index 0f86582..9444aa4 100644 ---

[PATCH 07/11] test/tagging: add tests for exotic tags

2012-12-25 Thread da...@tethera.net
From: David Bremner We test quotes seperately because they matter to the query escaper. --- test/tagging | 66 ++ 1 file changed, 66 insertions(+) diff --git a/test/tagging b/test/tagging index 405ad7c..417112b

[PATCH 04/11] cli: add support for batch tagging operations to "notmuch tag"

2012-12-25 Thread da...@tethera.net
From: Jani Nikula Add support for batch tagging operations through stdin to "notmuch tag". This can be enabled with the new --batch command line option to "notmuch tag". The input must consist of lines of the format: +|- [...] [--] [...] Each line is interpreted similarly to

[PATCH 06/11] test/tagging: add basic tests for batch tagging functionality

2012-12-25 Thread da...@tethera.net
From: David Bremner This tests argument parsing, blank lines and comments, and basic hex decoding functionality. --- test/tagging | 51 +++ 1 file changed, 51 insertions(+) diff --git a/test/tagging b/test/tagging index

[PATCH 11/11] test/tagging: add test for naked punctuation in tags; compare with quoting spaces.

2012-12-25 Thread da...@tethera.net
From: David Bremner This test also serves as documentation of the quoting requirements. The comment lines are so that it exactly matches the man page. Nothing more embarrassing than having an example in the man page fail. --- test/tagging | 25 + 1

[PATCH 10/11] man: document notmuch tag --batch, --input options

2012-12-25 Thread da...@tethera.net
From: Jani Nikula --- man/man1/notmuch-tag.1 | 92 1 file changed, 92 insertions(+) diff --git a/man/man1/notmuch-tag.1 b/man/man1/notmuch-tag.1 index 9444aa4..3aa2fa5 100644 --- a/man/man1/notmuch-tag.1 +++

[PATCH] NEWS for emacs part visibility change

2012-12-25 Thread David Bremner
Mark Walters writes: > Wording suggested by Austin. > --- pushed. d

[PATCH] emacs: tweak error buffer handling

2012-12-25 Thread Tomi Ollila
On Sat, Dec 22 2012, Mark Walters wrote: > view-mode-enter changed between emacs 23 and emacs 24: the current > code makes the error buffer disappear in emacs 24 on quitting it (ie > pressing q) but this just kills the buffer without closing the split > window in emacs 23. > > This patch makes

[PATCH 2/5] util: Function to parse boolean term queries

2012-12-25 Thread Austin Clements
Quoth David Bremner on Dec 25 at 10:18 am: > Austin Clements writes: > > > +if (consume_double_quote ()) { > > + char *out = talloc_strdup (ctx, pos); > > + pos = *term_out = out; > > + while (1) { > > Overall the control flow here is a bit tricky to follow. I'm not sure if > a real

[PATCH] contrib: pick: close message pane when quitting from show in the message pane

2012-12-25 Thread David Bremner
Mark Walters writes: > We add a hook to the show buffer in the message window to close the > message window when that buffer quits. It checks that the > message-window is still displaying the show-message buffer and then > closes it. pushed. d

[PATCH v2 2/5] util: Function to parse boolean term queries

2012-12-25 Thread Austin Clements
This parses the subset of Xapian's boolean term quoting rules that are used by make_boolean_term. This is provided as a generic string utility, but will be used shortly in notmuch restore to parse and optimize for ID queries. --- util/string-util.c | 51

[PATCH v2 5/5] man: Update notmuch-dump(1) and notmuch-restore(1)

2012-12-25 Thread Austin Clements
Describe the new batch-tag format. For notmuch-restore, rather than half-heartedly duplicating the description, we now cite notmuch-dump. --- man/man1/notmuch-dump.1| 11 +++ man/man1/notmuch-restore.1 |6 ++ 2 files changed, 9 insertions(+), 8 deletions(-) diff --git

[PATCH v2 1/5] util: Factor out boolean term quoting routine

2012-12-25 Thread Austin Clements
From: Austin Clements This is now a generic boolean term quoting function. It performs minimal quoting to produce user-friendly queries. This could live in tag-util as well, but it is really nothing specific to tags (although the conventions are specific to Xapian). The API

[PATCH v2 3/5] dump: Disallow \n in message IDs

2012-12-25 Thread Austin Clements
When we switch to using regular Xapian queries in the dump format, \n will cause problems, so we disallow it. Specially, while Xapian can quote and parse queries containing \n without difficultly, quoted queries containing \n still span multiple lines, which breaks the line-orientedness of the

[PATCH v2 0/5] Use Xapian query syntax for batch-tag dump/restore

2012-12-25 Thread Austin Clements
This obsoletes id:1356415076-5692-1-git-send-email-amdragon at mit.edu In addition to incorporating all of David's suggestions, this reworks the boolean term parsing so it only handles the subset of quoting syntax used by make_boolean_term (which also happens to be all that we described in the

[PATCH v2 4/5] dump/restore: Use Xapian queries for batch-tag format

2012-12-25 Thread Austin Clements
This switches the new batch-tag format away from using a home-grown hex-encoding scheme for message IDs in the dump to simply using Xapian queries with Xapian quoting syntax. This has a variety of advantages beyond presenting a cleaner and more consistent interface. Foremost is that it will