[PATCH V3 1/1] NEWS: under-the-hood Emacs interface fixes

2012-12-09 Thread Tomi Ollila
Added the following Emacs Interface NEWS entries: Catch errors bodypart insertions may throw, Improved text/calendar content handling and Disabled coding conversions when reading in `with-current-notmuch-show-message`. Thanks to Austin and David for content improvements. --- v2:

Re: v5 of Batch-tag dump/restore patches

2012-12-09 Thread David Bremner
da...@tethera.net writes: Yet another version. Luckily we all use threaded mailreaders, right? A few fixups Jani mentioned in IRC: commit 4cbd366d3cd29b5d26b36f3744c26b0853b23437 Author: David Bremner brem...@debian.org Date: Sun Dec 9 08:49:29 2012 -0400 remove unused sigatomic_t from

[PATCH v4 0/3] indicate length of omitted body content

2012-12-09 Thread Mark Walters
This is a (trivially) rebased version of id:1344428872-12374-1-git-send-email-noval...@gmail.com (There was one bit of context clash, and a small change to one of the sexp tests to mirror the same change for the json test) The patch is Peter's not mine so as a reviewer +1 from me. Best wishes

[PATCH v4 1/3] test: normalize only message filenames in show json

2012-12-09 Thread Mark Walters
From: Peter Wang noval...@gmail.com notmuch_json_show_sanitize replaced filename field values even in part structures, where the value is predictable. Make it only normalize the filename value if it is an absolute path (begins with slash), which is true of the Maildir filenames that were

[PATCH v4 2/3] show: indicate length, encoding of omitted body content

2012-12-09 Thread Mark Walters
From: Peter Wang noval...@gmail.com If a leaf part's body content is omitted, return the encoded length and transfer encoding in --format=json output. This information may be used by the consumer, e.g. to decide whether to download a large attachment over a slow link. Returning the _encoded_

[PATCH v4 3/3] test: conform to content length, encoding fields

2012-12-09 Thread Mark Walters
From: Peter Wang noval...@gmail.com Update tests to expect content-length and content-transfer-encoding fields in show --format=json output, for leaf parts with omitted body content. --- test/crypto| 30 +- test/json |4 +++- test/multipart |9

Re: v5 of Batch-tag dump/restore patches

2012-12-09 Thread Jani Nikula
On Sun, 09 Dec 2012, David Bremner da...@tethera.net wrote: da...@tethera.net writes: Yet another version. Luckily we all use threaded mailreaders, right? A few fixups Jani mentioned in IRC: The series with fixups LGTM. Jani. commit 4cbd366d3cd29b5d26b36f3744c26b0853b23437 Author:

[PATCH v2 0/4] cli: add notmuch search --format=text0

2012-12-09 Thread Jani Nikula
This is v2 of [1], with a rebase, disallowing --format=text0 --output=summary combination per Mark's suggestion, and adding man page and tests. BR, Jani. [1] id:30f03a18ed10c221c13b6672f90654963c76452d.1354832980.git.j...@nikula.org Jani Nikula (4): sprinter: add text0 formatter for null

[PATCH v2 1/4] sprinter: add text0 formatter for null character separated text

2012-12-09 Thread Jani Nikula
Same as the text formatter, but with each field separated by a null character rather than a newline character. --- sprinter-text.c | 22 ++ sprinter.h |6 ++ 2 files changed, 28 insertions(+) diff --git a/sprinter-text.c b/sprinter-text.c index 10343be..7779488

[PATCH v2 2/4] cli: add --format=text0 to notmuch search

2012-12-09 Thread Jani Nikula
Add new format text0, which is otherwise the same as text, but use the null character as separator instead of the newline character. This is similar to find(1) -print0 option, and works together with the xargs(1) -0 option. --- notmuch-search.c | 16 ++-- 1 file changed, 14

[PATCH v2 3/4] test: notmuch search --format=text0

2012-12-09 Thread Jani Nikula
--- test/text | 29 + 1 file changed, 29 insertions(+) diff --git a/test/text b/test/text index 428c89b..e003a66 100755 --- a/test/text +++ b/test/text @@ -52,4 +52,33 @@ output=$(notmuch search --format=text tëxt-search-méssage | notmuch_search_s

[PATCH v2 4/4] man: document notmuch search --format=text0

2012-12-09 Thread Jani Nikula
--- man/man1/notmuch-search.1 | 26 -- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/man/man1/notmuch-search.1 b/man/man1/notmuch-search.1 index 0aff348..22bcd0a 100644 --- a/man/man1/notmuch-search.1 +++ b/man/man1/notmuch-search.1 @@ -25,9 +25,11 @@

Re: [PATCH v2 0/4] cli: add notmuch search --format=text0

2012-12-09 Thread Mark Walters
This looks good to me. +1 Mark On Sun, 09 Dec 2012, Jani Nikula j...@nikula.org wrote: This is v2 of [1], with a rebase, disallowing --format=text0 --output=summary combination per Mark's suggestion, and adding man page and tests. BR, Jani. [1]

Re: v5 of Batch-tag dump/restore patches

2012-12-09 Thread Mark Walters
This series looks good to me too. +1 Best wishes Mark On Sun, 09 Dec 2012, David Bremner da...@tethera.net wrote: da...@tethera.net writes: Yet another version. Luckily we all use threaded mailreaders, right? A few fixups Jani mentioned in IRC: commit

Re: [PATCH v4 0/3] indicate length of omitted body content

2012-12-09 Thread Mark Walters
On Sun, 09 Dec 2012, Mark Walters markwalters1...@gmail.com wrote: This is a (trivially) rebased version of id:1344428872-12374-1-git-send-email-noval...@gmail.com (There was one bit of context clash, and a small change to one of the sexp tests to mirror the same change for the json test)

[PATCH] contrib: pick: bugfix for pick splitting the window excessively

2012-12-09 Thread Mark Walters
Previously if you carried on past the last message in a pick view pick would get confused and `forget' about the split pane and would try and re-split when moving up again. This was due to faulty logic in notmuch-pick-show-message: something that should have been in the (when message) clause was

[PATCH] contrib: pick: Do not indent messages in the message pane

2012-12-09 Thread Mark Walters
Currently pick just uses notmuch-show to display messages in the message pane: this means that they get indented just as show would. However, since pick is only displaying one message at a time there is no need to indent so override the indentation. --- Thanks to jrollins for the suggestion. It

Re: v5 of Batch-tag dump/restore patches

2012-12-09 Thread David Bremner
da...@tethera.net writes: Yet another version. Luckily we all use threaded mailreaders, right? This obsoletes id:1354979276-20099-1-git-send-email-da...@tethera.net I pushed this series, amended as described. d ___ notmuch mailing list

Re: [PATCH v2] emacs: add support for stashing the thread id in show view

2012-12-09 Thread David Bremner
Jani Nikula j...@nikula.org writes: Add a prefix argument to notmuch-show-stash-message-id to stash thread id instead of message id. pushed. d ___ notmuch mailing list notmuch@notmuchmail.org http://notmuchmail.org/mailman/listinfo/notmuch

Re: gmail importer script

2012-12-09 Thread Jason A. Donenfeld
On Sat, Dec 8, 2012 at 6:46 PM, Patrick Totzke patricktot...@gmail.comwrote: ZeroDivisionError: float division by zero Fixed it! Sorry about all this... Jeeze Louise. Another feature request: Could you make the progressbar stuff optinal? in the end one will want to run this via cronjob

V6 batch tagging patches.

2012-12-09 Thread david
This obsoletes the remaining patches in id:1353792017-31459-1-git-send-email-da...@tethera.net This isn't really v6 of these particular patches, but oh well. ___ notmuch mailing list notmuch@notmuchmail.org

[Patch v6 1/6] tag-util: factor out rules for illegal tags, use in parse_tag_line

2012-12-09 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 | 35 ++- 1 file changed, 30 insertions(+), 5 deletions(-) diff --git a/tag-util.c

[Patch v6 5/6] notmuch-tag.1: tidy synopsis formatting

2012-12-09 Thread david
From: David Bremner brem...@debian.org Consistently use [...]; one less space. --- man/man1/notmuch-tag.1 |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/man/man1/notmuch-tag.1 b/man/man1/notmuch-tag.1 index 0f86582..d23700d 100644 --- a/man/man1/notmuch-tag.1 +++

[Patch v6 6/6] man: document notmuch tag --batch, --input options

2012-12-09 Thread david
From: Jani Nikula j...@nikula.org --- man/man1/notmuch-tag.1 | 50 1 file changed, 50 insertions(+) diff --git a/man/man1/notmuch-tag.1 b/man/man1/notmuch-tag.1 index d23700d..c4e60d3 100644 --- a/man/man1/notmuch-tag.1 +++

[Patch v6 2/6] notmuch-tag.c: convert to use tag-utils

2012-12-09 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 v6 4/6] test: add test for notmuch tag --batch option

2012-12-09 Thread david
From: Jani Nikula j...@nikula.org Basic test of functionality, along with all combinations of options. Modified extensively by David Bremner da...@tethera.net The choice of @ as a tag is intended to be non-alphanumeric, but still not too much trouble in the shell and in the old sup dump/restore

[Patch v6 3/6] cli: add support for batch tagging operations to notmuch tag

2012-12-09 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 [...] [--] search-terms Each line is interpreted

Re: V6 batch tagging patches.

2012-12-09 Thread David Bremner
da...@tethera.net writes: This obsoletes the remaining patches in id:1353792017-31459-1-git-send-email-da...@tethera.net This isn't really v6 of these particular patches, but oh well. I forgot to mention that I will probably add some more tests; several of the dump/restore batch-tag

Re: [PATCH v2 1/6] test: emacs: new tests notmuch-show: {add, remove} multiple tags {to, from} single message

2012-12-09 Thread David Bremner
Pieter Praet pie...@praet.org writes: * test/emacs: - Rename subtests {Add,Remove} tag from notmuch-show view to notmuch-show: {add,remove} single tag {to,from} single message to be consistent with the following tests. - New subtest notmuch-show: add multiple tags to single

Encoding issue masks message reply

2012-12-09 Thread hellekin
Hola, using Emacs, when I try to reply to a message with ISO-8859-1 encoding (e.g. coming from Gmail), the body of the message is not quoted, and does not appear at all in the reply buffer. See the file attached, and the JSON produced by running: notmuch reply --format=json id:the-message-id

[PATCH] test: Adding non-maildir tags does not move message from new to cur

2012-12-09 Thread Jani Nikula
On Sat, 08 Dec 2012, david at tethera.net wrote: > From: Michal Sojka > > Some MUA's like mutt show the difference between "new" emails living in > maildir > directory new/, and "old" emails living in maildir directory cur/. However > notmuch tag unconditionally moves selected messages from new/

[PATCH] TODO: date range queries - check

2012-12-09 Thread Jani Nikula
On Sat, 08 Dec 2012, Jameson Graef Rollins wrote: > On Sat, Dec 08 2012, David Bremner wrote: >> Patch? Concrete wording suggestion? > > How about: > > It would be nice to not require both endpoints to be specified in date > searches. For example it would be nice to be able to say things like

[PATCH] TODO: date range queries - check

2012-12-09 Thread Tomi Ollila
On Sun, Dec 09 2012, Jani Nikula wrote: > On Sat, 08 Dec 2012, Jameson Graef Rollins > wrote: >> On Sat, Dec 08 2012, David Bremner wrote: >>> Patch? Concrete wording suggestion? >> >> How about: >> >> It would be nice to not require both endpoints to be specified in date >> searches. For

[PATCH] emacs/show: add command to view a patch using diff mode

2012-12-09 Thread Mark Walters
From: markwalters1...@gmail.com This enables fast navigation between hunks and better highlighting. The use of notmuch-get-bodypart-internal could be improved; hard coding to 1 seems to work for the output of git-format-patch. It also not so nice to call (insert (notmuch-get-bodypart-internal

[PATCH V3 1/1] NEWS: under-the-hood Emacs interface fixes

2012-12-09 Thread Tomi Ollila
Added the following Emacs Interface NEWS entries: Catch errors bodypart insertions may throw, Improved text/calendar content handling and Disabled coding conversions when reading in `with-current-notmuch-show-message`. Thanks to Austin and David for content improvements. --- v2:

v5 of Batch-tag dump/restore patches

2012-12-09 Thread David Bremner
david at tethera.net writes: > Yet another version. Luckily we all use threaded mailreaders, right? > A few fixups Jani mentioned in IRC: commit 4cbd366d3cd29b5d26b36f3744c26b0853b23437 Author: David Bremner Date: Sun Dec 9 08:49:29 2012 -0400 remove unused sigatomic_t from

[PATCH v4 0/3] indicate length of omitted body content

2012-12-09 Thread Mark Walters
This is a (trivially) rebased version of id:1344428872-12374-1-git-send-email-novalazy at gmail.com (There was one bit of context clash, and a small change to one of the sexp tests to mirror the same change for the json test) The patch is Peter's not mine so as a reviewer +1 from me. Best

[PATCH v4 1/3] test: normalize only message filenames in show json

2012-12-09 Thread Mark Walters
From: Peter Wang notmuch_json_show_sanitize replaced "filename" field values even in part structures, where the value is predictable. Make it only normalize the filename value if it is an absolute path (begins with slash), which is true of the Maildir filenames that were

[PATCH v4 2/3] show: indicate length, encoding of omitted body content

2012-12-09 Thread Mark Walters
From: Peter Wang If a leaf part's body content is omitted, return the encoded length and transfer encoding in --format=json output. This information may be used by the consumer, e.g. to decide whether to download a large attachment over a slow link. Returning the _encoded_

[PATCH v4 3/3] test: conform to content length, encoding fields

2012-12-09 Thread Mark Walters
From: Peter Wang Update tests to expect content-length and content-transfer-encoding fields in show --format=json output, for leaf parts with omitted body content. --- test/crypto| 30 +- test/json |4 +++- test/multipart |9

v5 of Batch-tag dump/restore patches

2012-12-09 Thread Jani Nikula
On Sun, 09 Dec 2012, David Bremner wrote: > david at tethera.net writes: > >> Yet another version. Luckily we all use threaded mailreaders, right? >> > > A few fixups Jani mentioned in IRC: The series with fixups LGTM. Jani. > > commit 4cbd366d3cd29b5d26b36f3744c26b0853b23437 > Author: David

[PATCH v2 0/4] cli: add notmuch search --format=text0

2012-12-09 Thread Jani Nikula
This is v2 of [1], with a rebase, disallowing --format=text0 --output=summary combination per Mark's suggestion, and adding man page and tests. BR, Jani. [1] id:30f03a18ed10c221c13b6672f90654963c76452d.1354832980.git.jani at nikula.org Jani Nikula (4): sprinter: add text0 formatter for

[PATCH v2 1/4] sprinter: add text0 formatter for null character separated text

2012-12-09 Thread Jani Nikula
Same as the text formatter, but with each field separated by a null character rather than a newline character. --- sprinter-text.c | 22 ++ sprinter.h |6 ++ 2 files changed, 28 insertions(+) diff --git a/sprinter-text.c b/sprinter-text.c index 10343be..7779488

[PATCH v2 2/4] cli: add --format=text0 to notmuch search

2012-12-09 Thread Jani Nikula
Add new format text0, which is otherwise the same as text, but use the null character as separator instead of the newline character. This is similar to find(1) -print0 option, and works together with the xargs(1) -0 option. --- notmuch-search.c | 16 ++-- 1 file changed, 14

[PATCH v2 3/4] test: notmuch search --format=text0

2012-12-09 Thread Jani Nikula
--- test/text | 29 + 1 file changed, 29 insertions(+) diff --git a/test/text b/test/text index 428c89b..e003a66 100755 --- a/test/text +++ b/test/text @@ -52,4 +52,33 @@ output=$(notmuch search --format=text "t?xt-search-m?ssage" | notmuch_search_s

[PATCH v2 4/4] man: document notmuch search --format=text0

2012-12-09 Thread Jani Nikula
--- man/man1/notmuch-search.1 | 26 -- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/man/man1/notmuch-search.1 b/man/man1/notmuch-search.1 index 0aff348..22bcd0a 100644 --- a/man/man1/notmuch-search.1 +++ b/man/man1/notmuch-search.1 @@ -25,9 +25,11 @@

[PATCH v2 0/4] cli: add notmuch search --format=text0

2012-12-09 Thread Mark Walters
This looks good to me. +1 Mark On Sun, 09 Dec 2012, Jani Nikula wrote: > This is v2 of [1], with a rebase, disallowing --format=text0 --output=summary > combination per Mark's suggestion, and adding man page and tests. > > BR, > Jani. > > > [1]

v5 of Batch-tag dump/restore patches

2012-12-09 Thread Mark Walters
This series looks good to me too. +1 Best wishes Mark On Sun, 09 Dec 2012, David Bremner wrote: > david at tethera.net writes: > >> Yet another version. Luckily we all use threaded mailreaders, right? >> > > A few fixups Jani mentioned in IRC: > > commit

Notmuch scripts (again), now with more usenet

2012-12-09 Thread Jani Nikula
On Sat, 14 Jul 2012, ccx at webprojekty.cz wrote: > Hello, for quite some time my set of scripts just lied in my repo and > waited for polish before release. So tonight I finally managed to update > the docs, remove old stuff, rewrite some unfortunate things etc. > > One notable addition is

[PATCH v4 0/3] indicate length of omitted body content

2012-12-09 Thread Mark Walters
On Sun, 09 Dec 2012, Mark Walters wrote: > This is a (trivially) rebased version of > id:1344428872-12374-1-git-send-email-novalazy at gmail.com (There was one > bit of context clash, and a small change to one of the sexp tests to > mirror the same change for the json test) > > > The patch is

[PATCH] contrib: pick: bugfix for pick splitting the window excessively

2012-12-09 Thread Mark Walters
Previously if you carried on past the last message in a pick view pick would get confused and `forget' about the split pane and would try and re-split when moving up again. This was due to faulty logic in notmuch-pick-show-message: something that should have been in the (when message) clause was

[PATCH] contrib: pick: Do not indent messages in the message pane

2012-12-09 Thread Mark Walters
Currently pick just uses notmuch-show to display messages in the message pane: this means that they get indented just as show would. However, since pick is only displaying one message at a time there is no need to indent so override the indentation. --- Thanks to jrollins for the suggestion. It

v5 of Batch-tag dump/restore patches

2012-12-09 Thread David Bremner
david at tethera.net writes: > Yet another version. Luckily we all use threaded mailreaders, right? > > This obsoletes > > id:1354979276-20099-1-git-send-email-david at tethera.net I pushed this series, amended as described. d

[PATCH v2] emacs: add support for stashing the thread id in show view

2012-12-09 Thread David Bremner
Jani Nikula writes: > Add a prefix argument to notmuch-show-stash-message-id to stash thread > id instead of message id. pushed. d

V6 batch tagging patches.

2012-12-09 Thread da...@tethera.net
This obsoletes the remaining patches in id:1353792017-31459-1-git-send-email-david at tethera.net This isn't really v6 of these particular patches, but oh well.

[Patch v6 1/6] tag-util: factor out rules for illegal tags, use in parse_tag_line

2012-12-09 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 | 35 ++- 1 file changed, 30 insertions(+), 5 deletions(-) diff --git a/tag-util.c

[Patch v6 5/6] notmuch-tag.1: tidy synopsis formatting

2012-12-09 Thread da...@tethera.net
From: David Bremner Consistently use [...]; one less space. --- man/man1/notmuch-tag.1 |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/man/man1/notmuch-tag.1 b/man/man1/notmuch-tag.1 index 0f86582..d23700d 100644 --- a/man/man1/notmuch-tag.1 +++

[Patch v6 6/6] man: document notmuch tag --batch, --input options

2012-12-09 Thread da...@tethera.net
From: Jani Nikula --- man/man1/notmuch-tag.1 | 50 1 file changed, 50 insertions(+) diff --git a/man/man1/notmuch-tag.1 b/man/man1/notmuch-tag.1 index d23700d..c4e60d3 100644 --- a/man/man1/notmuch-tag.1 +++

[Patch v6 2/6] notmuch-tag.c: convert to use tag-utils

2012-12-09 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 v6 4/6] test: add test for notmuch tag --batch option

2012-12-09 Thread da...@tethera.net
From: Jani Nikula Basic test of functionality, along with all combinations of options. Modified extensively by David Bremner The choice of @ as a tag is intended to be non-alphanumeric, but still not too much trouble in the shell and in the old sup dump/restore format. ---

[Patch v6 3/6] cli: add support for batch tagging operations to "notmuch tag"

2012-12-09 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

V6 batch tagging patches.

2012-12-09 Thread David Bremner
david at tethera.net writes: > This obsoletes the remaining patches in > > id:1353792017-31459-1-git-send-email-david at tethera.net > > This isn't really v6 of these particular patches, but oh well. I forgot to mention that I will probably add some more tests; several of the dump/restore

[PATCH v2 1/6] test: emacs: new tests "notmuch-show: {add, remove} multiple tags {to, from} single message"

2012-12-09 Thread David Bremner
Pieter Praet writes: > * test/emacs: > > - Rename subtests "{Add,Remove} tag from notmuch-show view" to > "notmuch-show: {add,remove} single tag {to,from} single message" > to be consistent with the following tests. > > - New subtest "notmuch-show: add multiple tags to single