[PATCH v3 0/3] emacs: do not call notmuch show for non-inlinable parts

2011-11-29 Thread Dmitry Kurochkin
Make some changes suggested by Tomi Ollila [1]. Changes: v3 since v2: * Use read function instead of cat(1) to read counter value. * Add a newline after the count value in state file and notmuch_counter_value() output. v2 since v1: * Rename $notmuch_counter variable to $notmuch_counter_comma

[PATCH v3 1/3] test: add functions to count how much times notmuch was called

2011-11-29 Thread Dmitry Kurochkin
The patch adds two auxiliary functions and a variable: notmuch_counter_reset $notmuch_counter_command notmuch_counter_value They allow to count how many times notmuch binary is called. notmuch_counter_reset() function generates a script that counts how many times it is called and resets the

[PATCH v3 2/3] test: check that Emacs UI does not call notmuch for non-inlinable parts

2011-11-29 Thread Dmitry Kurochkin
The patch adds two new test cases: * Do not call notmuch for non-inlinable application/mpeg parts * Do not call notmuch for non-inlinable audio/mpeg parts The application/mpeg test passes thanks to a workaround for application/* Content-Types. The audio/mpeg is currently broken. --- test/emacs

[PATCH v3 3/3] emacs: do not call notmuch show for non-inlinable parts

2011-11-29 Thread Dmitry Kurochkin
Before the change, there was a workaround to avoid notmuch show calls for parts with application/* Content-Type. But non-inlinable parts are not limited to this Content-Type (e.g. mp3 files have audio/mpeg Content-Type and are not inlinable). For such parts `notmuch-show-insert-part-*/*' handler

Re: [PATCH 1/3] test: add functions to count how much times notmuch was called

2011-11-29 Thread Dmitry Kurochkin
Hi Tomi. On Mon, 28 Nov 2011 22:42:50 +0200, Tomi Ollila wrote: > On Mon, 28 Nov 2011 07:28:13 +0400, Dmitry Kurochkin > wrote: > > [...] > > + > > +These allow to count how many times notmuch binary is called. > > +notmuch_counter_reset() function

Re: [PATCH 4/9] test: add support for external executable dependencies

2011-11-29 Thread Dmitry Kurochkin
On Mon, 28 Nov 2011 23:16:27 +0200, Tomi Ollila wrote: > On Thu, 17 Nov 2011 05:56:21 +0400, Dmitry Kurochkin > wrote: > > There is existing support for general prerequisites in the test suite. > > But it is not very convenient to use: every test case has to keep > > tra

Re: [PATCH 4/9] test: add support for external executable dependencies

2011-11-29 Thread Dmitry Kurochkin
On Tue, 29 Nov 2011 01:53:49 +0400, Dmitry Kurochkin wrote: > On Mon, 28 Nov 2011 23:16:27 +0200, Tomi Ollila wrote: > > On Thu, 17 Nov 2011 05:56:21 +0400, Dmitry Kurochkin > > wrote: > > > There is existing support for general prerequisites in the test suite.

[PATCH 0/4] fix a bunch of bugs in recently added binary dependencies

2011-11-29 Thread Dmitry Kurochkin
Hello. This is a series of trivial but important fixes for the recently added binary dependencies. Special thanks goes to Tomi Ollila who did review of the original patches. Regards, Dmitry ___ notmuch mailing list notmuch@notmuchmail.org http://not

[PATCH 1/4] test: fix test_require_external_prereq()

2011-11-29 Thread Dmitry Kurochkin
test_missing_external_prereq_${binary}_ variable indicates that the binary is missing. It must be set in test_declare_external_prereq() outside of the fake $binary() function. --- test/test-lib.sh |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/test/test-lib.sh b/test/te

[PATCH 2/4] test: add missing escape backslash in test_declare_external_prereq()

2011-11-29 Thread Dmitry Kurochkin
--- test/test-lib.sh |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/test/test-lib.sh b/test/test-lib.sh index d7282ff..9dcb2d2 100644 --- a/test/test-lib.sh +++ b/test/test-lib.sh @@ -557,7 +557,7 @@ test_declare_external_prereq () { test_missing_external_prereq_

[PATCH 3/4] test: fix spurious output from missing external binaries functions

2011-11-29 Thread Dmitry Kurochkin
The grep(1) command used in the fake binary functions was missing the quiet option. --- test/test-lib.sh |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/test/test-lib.sh b/test/test-lib.sh index 9dcb2d2..2861d88 100644 --- a/test/test-lib.sh +++ b/test/test-lib.sh @@ -556

[PATCH 4/4] test: fix error messages for missing binary dependencies

2011-11-29 Thread Dmitry Kurochkin
The fake missing binary functions check if the binary has already be added to the diagnostic message to avoid duplicates. Unfortunately, this check was buggy because the message string does not have the trailing space. --- test/test-lib.sh |2 +- 1 files changed, 1 insertions(+), 1 deletions(

Re: [PATCH 1/2] emacs: remove some code duplication in notmuch-show

2011-11-29 Thread Dmitry Kurochkin
Hi Jamie. On Mon, 28 Nov 2011 06:24:19 -0800, Jameson Graef Rollins wrote: > On Sat, 26 Nov 2011 02:23:30 +0400, Dmitry Kurochkin > wrote: > > -(defun notmuch-show-get-header (header) > > +(defun notmuch-show-get-header (header &optional props) > >"Retur

Re: [PATCH 4/9] test: add support for external executable dependencies

2011-11-29 Thread Dmitry Kurochkin
On Tue, 29 Nov 2011 02:13:53 +0400, Dmitry Kurochkin wrote: > On Tue, 29 Nov 2011 01:53:49 +0400, Dmitry Kurochkin > wrote: > > On Mon, 28 Nov 2011 23:16:27 +0200, Tomi Ollila wrote: > > > On Thu, 17 Nov 2011 05:56:21 +0400, Dmitry Kurochkin > > > wrote: >

Re: [PATCH 1/3] test: add functions to count how much times notmuch was called

2011-11-29 Thread Dmitry Kurochkin
Hi Tomi. On Tue, 29 Nov 2011 14:58:00 +0200, Tomi Ollila wrote: > Hi Dmitry. > > On Tue, 29 Nov 2011 01:26:39 +0400, Dmitry Kurochkin > wrote: > > Hi Tomi. > > > > On Mon, 28 Nov 2011 22:42:50 +0200, Tomi Ollila wrote: > > > On Mon, 28 Nov 2011 07:28:1

[PATCH v4 0/3] emacs: do not call notmuch show for non-inlinable parts

2011-11-29 Thread Dmitry Kurochkin
Changes: v4 since v3: * Use $(()) instead of expr(1) for math. v3 since v2: * Use read function instead of cat(1) to read counter value. * Add a newline after the count value in state file and notmuch_counter_value() output. v2 since v1: * Rename $notmuch_counter variable to $notmuch_counte

[PATCH v4 2/3] test: check that Emacs UI does not call notmuch for non-inlinable parts

2011-11-29 Thread Dmitry Kurochkin
The patch adds two new test cases: * Do not call notmuch for non-inlinable application/mpeg parts * Do not call notmuch for non-inlinable audio/mpeg parts The application/mpeg test passes thanks to a workaround for application/* Content-Types. The audio/mpeg is currently broken. --- test/emacs

[PATCH v4 3/3] emacs: do not call notmuch show for non-inlinable parts

2011-11-29 Thread Dmitry Kurochkin
Before the change, there was a workaround to avoid notmuch show calls for parts with application/* Content-Type. But non-inlinable parts are not limited to this Content-Type (e.g. mp3 files have audio/mpeg Content-Type and are not inlinable). For such parts `notmuch-show-insert-part-*/*' handler

[PATCH v4 1/3] test: add functions to count how much times notmuch was called

2011-11-29 Thread Dmitry Kurochkin
The patch adds two auxiliary functions and a variable: notmuch_counter_reset $notmuch_counter_command notmuch_counter_value They allow to count how many times notmuch binary is called. notmuch_counter_reset() function generates a script that counts how many times it is called and resets the

Re: [PATCH] emacs: Use notmuch-command variable in process-lines.

2011-11-29 Thread Dmitry Kurochkin
+1 Regards, Dmitry ___ notmuch mailing list notmuch@notmuchmail.org http://notmuchmail.org/mailman/listinfo/notmuch

[PATCH] test: cleanup gdb external dependency in atomicity tests

2011-12-01 Thread Dmitry Kurochkin
Change atomicity tests to use the new external binary dependencies. This simplifies the code and makes output consistent. --- test/atomicity | 12 1 files changed, 4 insertions(+), 8 deletions(-) diff --git a/test/atomicity b/test/atomicity index ad7d4a3..6df0a00 100755 --- a/test/

Re: [PATCH v4 0/3] emacs: do not call notmuch show for non-inlinable parts

2011-12-07 Thread Dmitry Kurochkin
Hi David. How about pushing this series? Just a humble ping :) Regards, Dmitry ___ notmuch mailing list notmuch@notmuchmail.org http://notmuchmail.org/mailman/listinfo/notmuch

Re: [PATCH 1/2] emacs: remove some code duplication in notmuch-show

2011-12-07 Thread Dmitry Kurochkin
David, this seems ready for push as well. Regards, Dmitry ___ notmuch mailing list notmuch@notmuchmail.org http://notmuchmail.org/mailman/listinfo/notmuch

Re: [PATCH] debian: add a recommends for w3m-el or w3m-el-snapshot to notmuch-emacs

2011-12-08 Thread Dmitry Kurochkin
Hi David. I am not sure recommending w3m-el is a good idea. It has very annoying bugs with scrolling (C-n): at some point the cursor jumps back above, i.e. it goes in a loop. I did not investigate the issue though. Regards, Dmitry ___ notmuch mailin

Re: [PATCH] debian: add a recommends for w3m-el or w3m-el-snapshot to notmuch-emacs

2011-12-08 Thread Dmitry Kurochkin
On Thu, 08 Dec 2011 08:32:12 -0400, David Bremner wrote: > On Thu, 08 Dec 2011 13:33:09 +0400, Dmitry Kurochkin > wrote: > > > I am not sure recommending w3m-el is a good idea. It has very annoying > > bugs with scrolling (C-n): at some point the cursor jumps back above,

Re: [PATCH v2 0/4] First step of 'show' rewrite

2011-12-09 Thread Dmitry Kurochkin
Hi Austin. On Fri, 9 Dec 2011 12:39:13 -0500, Austin Clements wrote: > Just a reminder that this series awaits review and is the first step > in a better, simpler, and cleaner show that will make possible things > like improvements to the JSON format, better encoding handling, proper > raw suppor

Re: [PATCH 1/4] show: Pass notmuch_message_t instead of path to show_message_body.

2011-12-09 Thread Dmitry Kurochkin
On Sun, 4 Dec 2011 14:31:37 -0500, Austin Clements wrote: > In addition to simplifying the code, we'll need the notmuch_message_t* > in show_message_body shortly. > --- > notmuch-client.h |2 +- > notmuch-reply.c |3 +-- > notmuch-show.c |3 +-- > show-message.c |3 ++- > 4

Re: [PATCH 1/4] show: Pass notmuch_message_t instead of path to show_message_body.

2011-12-09 Thread Dmitry Kurochkin
On Fri, 9 Dec 2011 14:54:26 -0500, Austin Clements wrote: > Quoth Dmitry Kurochkin on Dec 09 at 11:05 pm: > > On Sun, 4 Dec 2011 14:31:37 -0500, Austin Clements > > wrote: > > > } > > > > > > notmuch_status_t > > > -show_message_b

Re: [PATCH 2/4] Introduce a generic tree-like abstraction for MIME traversal.

2011-12-09 Thread Dmitry Kurochkin
Hi Austin. +/* The number of children of this part. */ +int children; Consider renaming to children_count or similar to make it clear that it is a counter and not the actual children. +notmuch_bool_t decrypt_success; Perhaps s/decrypt_success/is_decrypted/ for consistency with is_en

Re: [PATCH 3/4] Utility function to seek in MIME trees in depth-first order.

2011-12-10 Thread Dmitry Kurochkin
On Fri, 9 Dec 2011 14:54:27 -0500, Austin Clements wrote: > This function matches how we number parts for the --part argument to > show. It will allow us to jump directly to the desired part, rather > than traversing the entire tree and carefully tracking whether or not > we're "in the zone". >

Re: [PATCH 4/4] show: Rewrite show_message_body to use the MIME tree interface.

2011-12-11 Thread Dmitry Kurochkin
Hi Austin. I enjoyed reviewing this patch. It is a pleasure to see how complex and confusing code becomes much smaller and cleaner. I still have some questions with the new code. It seems confusing to me that part_content is called first and then go envelope headers. But I this is just the fir

Re: [PATCH v3 0/4] First step of 'show' rewrite

2011-12-11 Thread Dmitry Kurochkin
Austin, good job! :) Thanks for this work. (and continue, please :)) Most comments in my review are minor and/or concern the old code (i.e. the new code does not make it worse). Please feel free to ignore them. I vote for pushing this series as soon as Austin finds it appropriate. If Austin mak

Re: [PATCH 1/2] test: add a function to run Python tests

2011-12-11 Thread Dmitry Kurochkin
Hi Thomas. On Wed, 7 Dec 2011 10:46:17 +0100, Thomas Jost wrote: > The new test_python() function makes writing Python tests a little easier: > - it sets the environment variables as needed > - it redirects stdout to the OUTPUT file (like test_emacs()). > > This commit also declares python as a

Re: [PATCH] cli: factor out config handling code to get/set lists.

2011-12-11 Thread Dmitry Kurochkin
Hi David. On Sun, 11 Dec 2011 12:07:51 -0400, David Bremner wrote: > From: David Bremner > > Two new internal routines are created _config_get_list and > _config_set_list; the notmuch_config_get_* functions that deal with > lists are simply wrappers for these functions. Looks good to me. Some

Re: [PATCH] util/hex-escape.[ch]: encoding/decoding strings into restricted character set

2011-12-11 Thread Dmitry Kurochkin
On Sun, 11 Dec 2011 12:19:44 -0400, David Bremner wrote: > From: David Bremner > > The character set is chosen to be suitable for pathnames, and the same > as that used by contrib/nmbug. The new encoded/decoded strings are > allocated using talloc. > --- > This isn't urgent, but it is useful for

Re: [PATCH] emacs: support "notmuch new" as a notmuch-poll-script

2011-12-11 Thread Dmitry Kurochkin
Hi Jani. On Sun, 11 Dec 2011 23:48:20 +0200, Jani Nikula wrote: > Let notmuch-poll-script be a function as well as a string. Make default > value nil instead of an empty string, but allow "" for backwards > compatibility. Add a notmuch poll function to call "notmuch new" using the > configured no

Re: [PATCH] emacs: support "notmuch new" as a notmuch-poll-script

2011-12-11 Thread Dmitry Kurochkin
On Mon, 12 Dec 2011 00:19:36 +0200, Jani Nikula wrote: > > Hi Dmitry - > > On Mon, 12 Dec 2011 02:00:45 +0400, Dmitry Kurochkin > wrote: > > On Sun, 11 Dec 2011 23:48:20 +0200, Jani Nikula wrote: > > > Let notmuch-poll-script be a function as well as a string

Re: [PATCH] emacs: support "notmuch new" as a notmuch-poll-script

2011-12-11 Thread Dmitry Kurochkin
On Sun, 11 Dec 2011 19:31:03 -0500, Austin Clements wrote: > Quoth Jani Nikula on Dec 12 at 1:10 am: > >On Dec 12, 2011 12:56 AM, "Austin Clements" <[1]amdra...@mit.edu> wrote: > >> > >> Quoth Dmitry Kurochkin on Dec 12 at  2:00 am: >

Re: [PATCH] emacs: support "notmuch new" as a notmuch-poll-script

2011-12-12 Thread Dmitry Kurochkin
On Mon, 12 Dec 2011 12:15:44 +0200, Tomi Ollila wrote: > On Sun, 11 Dec 2011 19:31:03 -0500, Austin Clements wrote: > > > > So here's another idea, prefaced with a rant. > > > > It's bothered me for a long time that notmuch-emacs didn't just know > > by default how to check for new mail. What

Re: [PATCH v2] emacs: support "notmuch new" as a notmuch-poll-script

2011-12-12 Thread Dmitry Kurochkin
Hi Jani. On Mon, 12 Dec 2011 21:57:28 +0200, Jani Nikula wrote: > Support nil value for notmuch-poll-script to run "notmuch new" instead of > an external script, and make this the new default. "notmuch new" is run > using the configured notmuch-command. > > This allows taking better advantage of

Re: [PATCH v3] emacs: support "notmuch new" as a notmuch-poll-script

2011-12-12 Thread Dmitry Kurochkin
On Mon, 12 Dec 2011 22:50:04 +0200, Jani Nikula wrote: > Support nil value for notmuch-poll-script to run "notmuch new" instead of > an external script, and make this the new default. "notmuch new" is run > using the configured notmuch-command. > > This allows taking better advantage of the "notm

Re: [PATCH v3] emacs: support "notmuch new" as a notmuch-poll-script

2011-12-12 Thread Dmitry Kurochkin
On Mon, 12 Dec 2011 16:24:51 -0500, Austin Clements wrote: > Quoth Jani Nikula on Dec 12 at 11:13 pm: > > On Tue, 13 Dec 2011 00:53:05 +0400, Dmitry Kurochkin > > wrote: > > > On Mon, 12 Dec 2011 22:50:04 +0200, Jani Nikula wrote: > > > > +If set to nil (th

Re: [PATCH] notmuch: unref charset_filter to fix one memory leak

2011-12-13 Thread Dmitry Kurochkin
On Tue, 13 Dec 2011 14:03:33 +0200, Tomi Ollila wrote: > In my use case g_object_unref(charset_filter) reduces memory > consumption over 90% when 'notmuch show --format=text "*"' is > executed (~11000 messages, RES ~330M -> ~25M). > --- > notmuch-show.c |4 +++- > 1 files changed, 3 insertion

Re: [PATCH v3 4/4] emacs: add notmuch-hello-hook

2011-12-13 Thread Dmitry Kurochkin
On Tue, 13 Dec 2011 18:32:12 +0100, Thomas Jost wrote: > This hook is called every time the notmuch-hello buffer is updated. > --- > emacs/notmuch-hello.el |9 - > 1 files changed, 8 insertions(+), 1 deletions(-) > > diff --git a/emacs/notmuch-hello.el b/emacs/notmuch-hello.el > inde

Re: [PATCH] notmuch: unref charset_filter (once more) to fix one memory leak

2011-12-13 Thread Dmitry Kurochkin
On Tue, 13 Dec 2011 20:18:48 +0200, tomi.oll...@iki.fi wrote: > From: Tomi Ollila > > In my test case added g_object_unref(charset_filter) reduces memory > consumption over 90% when 'notmuch show --format=text "*"' is > executed (~11000 messages, RES ~330M -> ~25M). > --- > Thanks Dmitry. I did n

Re: [PATCH] test: optionally print subtest number

2011-12-13 Thread Dmitry Kurochkin
On Tue, 13 Dec 2011 15:56:47 -0400, David Bremner wrote: > From: David Bremner > > The idea is that $test_count could be used in tests to label > intermediate files. The output enabled by this patch (and --debug) > helps figure out which OUTPUT.nn file belongs to which test in case > several sub

Re: [PATCH] test: optionally print subtest number

2011-12-13 Thread Dmitry Kurochkin
On Tue, 13 Dec 2011 22:55:18 +0200, Tomi Ollila wrote: > On Wed, 14 Dec 2011 00:15:43 +0400, Dmitry Kurochkin > wrote: > > On Tue, 13 Dec 2011 15:56:47 -0400, David Bremner wrote: > > > From: David Bremner > > > > > > The idea is that $tes

Re: [PATCH] test: optionally print subtest number

2011-12-13 Thread Dmitry Kurochkin
On Tue, 13 Dec 2011 19:18:16 -0400, David Bremner wrote: > On Tue, 13 Dec 2011 14:22:21 -0800, Jameson Graef Rollins > wrote: > > > I've only been vaguely following this "test count" stuff, but I'm not > > sure I understand what's the point of giving tests a number that is > > ultimately mutabl

Re: [PATCH] test: optionally print subtest number

2011-12-13 Thread Dmitry Kurochkin
On Tue, 13 Dec 2011 15:35:53 -0800, Jameson Graef Rollins wrote: > On Wed, 14 Dec 2011 03:24:23 +0400, Dmitry Kurochkin > wrote: > > BTW I have some plans to introduce optional explicit test ids that can > > be used for inter-test dependencies. E.g.: > > > > t

Re: [PATCH v6 1/2] emacs: User-defined sections in notmuch-hello

2011-12-13 Thread Dmitry Kurochkin
Hi Daniel. I have finished reviewing this patch at last. Sorry, it is a bit messy. Overall, I like the patch. It is a very nice improvement. I am sure I have missed some important points, but I guess this is the best I can do right now. Perhaps I will find more comments for the next version of

Re: [PATCH v6 1/2] emacs: User-defined sections in notmuch-hello

2011-12-14 Thread Dmitry Kurochkin
On Wed, 14 Dec 2011 07:11:21 +0400, Dmitry Kurochkin wrote: > Hi Daniel. > > I have finished reviewing this patch at last. Sorry, it is a bit messy. > Overall, I like the patch. It is a very nice improvement. > > I am sure I have missed some important points, but I guess th

Re: [Alpha PATCH 6/6] test: second set of dump/restore --format=notmuch tests

2011-12-14 Thread Dmitry Kurochkin
On Tue, 13 Dec 2011 16:27:55 -0400, David Bremner wrote: > From: David Bremner > > These one need the completed functionality in notmuch-restore. Fairly > exotic tags are tested, but no weird message id's. > --- > test/dump-restore | 33 + > 1 files changed, 33

Re: [Alpha Patch 2/2] test: update dump-restore tests for 8 bit characters.

2011-12-14 Thread Dmitry Kurochkin
On Wed, 14 Dec 2011 16:14:01 -0400, David Bremner wrote: > From: David Bremner > > hex-escape: fix for handling of 8 bit chars > > The low level problem was passing negative numbers to sprintf(s,"%x"); > we fix this and clarify the api for hex_(decode|encode) by making > encode go from (unsigne

Re: [PATCH v3 2/4] emacs: Add a face for crypto parts headers

2011-12-15 Thread Dmitry Kurochkin
On Tue, 13 Dec 2011 18:32:10 +0100, Thomas Jost wrote: > Commit cb841878 introduced new parts handlers for crypto parts, but also > hardcoded values for their headers face. This replaces these hardcoded values > with a customizable face. > --- Looks good to me. Regards, Dmitry > emacs/notmuc

Re: [PATCH v3 3/4] emacs: rename notmuch-decimal-separator to notmuch-thousands-separator

2011-12-15 Thread Dmitry Kurochkin
On Tue, 13 Dec 2011 18:32:11 +0100, Thomas Jost wrote: > In 123,456.78, "." is the decimal separator, but "," is the thousands > separator. > > This commit also mentions the space being used as thousands separator in > several > European countries. > --- What do perople think about making the

Re: [PATCH] [emacs] Add an argument to notmuch-mua-mail

2011-12-16 Thread Dmitry Kurochkin
On Fri, 16 Dec 2011 05:30:39 -0500, Aaron Ecay wrote: > From the emacs changelog: > > ** `compose-mail' now accepts an optional 8th arg, RETURN-ACTION, and > passes it to the mail user agent function. This argument specifies an > action for returning to the caller after finishing with the

Re: [PATCH] [emacs] Add an argument to notmuch-mua-mail

2011-12-16 Thread Dmitry Kurochkin
On Fri, 16 Dec 2011 13:06:21 +0200, Tomi Ollila wrote: > On Fri, 16 Dec 2011 05:30:39 -0500, Aaron Ecay wrote: > > >From the emacs changelog: > > > > ** `compose-mail' now accepts an optional 8th arg, RETURN-ACTION, and > > passes it to the mail user agent function. This argument specifies

Re: [PATCH] [emacs] Add an argument to notmuch-mua-mail

2011-12-16 Thread Dmitry Kurochkin
On Fri, 16 Dec 2011 06:16:45 -0500, Aaron Ecay wrote: > From the emacs changelog: > > ** `compose-mail' now accepts an optional 8th arg, RETURN-ACTION, and > passes it to the mail user agent function. This argument specifies an > action for returning to the caller after finishing with the

Re: [PATCH 1/2] emacs: Fix notmuch-hello-tag-list-make-query defcustom

2011-12-16 Thread Dmitry Kurochkin
Hi Jani. On Fri, 23 Sep 2011 22:03:41 +0300, Jani Nikula wrote: > It was not possible to define custom filters or filter functions because > the types were const. Remove const to allow editing. > How about making "Unread messages" query configurable as well? Regards, Dmitry > Signed-off-by:

Re: [PATCH 1/2] emacs: Fix notmuch-hello-tag-list-make-query defcustom

2011-12-16 Thread Dmitry Kurochkin
On Fri, 16 Dec 2011 16:22:07 +0400, Dmitry Kurochkin wrote: > Hi Jani. > > On Fri, 23 Sep 2011 22:03:41 +0300, Jani Nikula wrote: > > It was not possible to define custom filters or filter functions because > > the types were const. Remove const to allow editing. >

Re: [PATCH 2/2] emacs: Fix notmuch-mua-user-agent defcustom

2011-12-16 Thread Dmitry Kurochkin
On Fri, 23 Sep 2011 22:03:42 +0300, Jani Nikula wrote: > The :options keyword is not meaningful for function type. Also, it was not > possible to enter nil value, contrary to the notmuch-mua-user-agent > defcustom documentation. Specify the alternatives using choice type, taking > nil into account

Re: [PATCH v3 3/4] emacs: rename notmuch-decimal-separator to notmuch-thousands-separator

2011-12-16 Thread Dmitry Kurochkin
On Fri, 16 Dec 2011 08:29:00 -0400, David Bremner wrote: > On Fri, 16 Dec 2011 04:59:22 +0400, Dmitry Kurochkin > wrote: > > > > What do perople think about making the thousands separator a space by > > default? > > > > Is that really good for a majori

Re: [PATCH v3 4/4] emacs: add notmuch-hello-hook

2011-12-16 Thread Dmitry Kurochkin
On Tue, 13 Dec 2011 21:49:00 +0400, Dmitry Kurochkin wrote: > On Tue, 13 Dec 2011 18:32:12 +0100, Thomas Jost wrote: > > This hook is called every time the notmuch-hello buffer is updated. > > --- > > emacs/notmuch-hello.el |9 - > > 1 files changed, 8

Re: [PATCH 3/3] test: add emacs test for hiding a message following an HTML part

2011-12-16 Thread Dmitry Kurochkin
Hi Tom. On Thu, 15 Dec 2011 10:27:33 -0700, Tom Prince wrote: > On Thu, 15 Dec 2011 08:14:08 -0400, David Bremner wrote: > > On Mon, 4 Jul 2011 05:59:03 +0400, Dmitry Kurochkin > > wrote: > > > Result: nothing happens except for "No URL at point" message

[PATCH 2/4] test: add test for `notmuch-hello-mode-hook'

2011-12-16 Thread Dmitry Kurochkin
Test that `notmuch-hello-mode-hook' is called once when `notmuch-hello' function is called. --- test/emacs |9 + 1 files changed, 9 insertions(+), 0 deletions(-) diff --git a/test/emacs b/test/emacs index 6e922de..a864ffa 100755 --- a/test/emacs +++ b/test/emacs @@ -476,4 +476,13 @@ t

[PATCH 1/4] test: add `notmuch-hello-mode-hook-counter'

2011-12-16 Thread Dmitry Kurochkin
Add `notmuch-hello-mode-hook-counter' hook to count how many times `notmuch-hello-mode-hook' was called. The counter function increments `notmuch-hello-mode-hook-counter' variable value if it is bount, otherwise it does nothing. --- test/test-lib.el |9 + 1 files changed, 9 insertions

[PATCH 3/4] test: add broken test for `notmuch-hello-mode-hook' called during update

2011-12-16 Thread Dmitry Kurochkin
Test that `notmuch-hello-mode-hook' is not called during `notmuch-hello' buffer updates. The test is currently broken. --- test/emacs | 11 +++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/test/emacs b/test/emacs index a864ffa..b4c2444 100755 --- a/test/emacs +++ b/te

[PATCH 4/4] emacs: do not call `notmuch-hello-mode' on update

2011-12-16 Thread Dmitry Kurochkin
`notmuch-hello' should call `notmuch-hello-mode' function only when run for the first time. But before the change, `notmuch-hello' used `kill-all-local-variables' to remove editable widgets fields. This caused the major mode to be reset, and `notmuch-hello-mode' to be called every time. The patc

Re: [PATCH] [emacs] Add an argument to notmuch-mua-mail

2011-12-17 Thread Dmitry Kurochkin
On Sat, 17 Dec 2011 05:41:28 -0500, Aaron Ecay wrote: > From the emacs changelog: > > ** `compose-mail' now accepts an optional 8th arg, RETURN-ACTION, and > passes it to the mail user agent function. This argument specifies an > action for returning to the caller after finishing with the

Re: [PATCH] [emacs] Add an argument to notmuch-mua-mail

2011-12-17 Thread Dmitry Kurochkin
Looks good to me. Regards, Dmitry ___ notmuch mailing list notmuch@notmuchmail.org http://notmuchmail.org/mailman/listinfo/notmuch

[PATCH v2 0/4] emacs: do not call `notmuch-hello-mode' on update

2011-12-17 Thread Dmitry Kurochkin
Changes in v2 since v1: * actually use `all' variable in `mapc' call, thanks Tomi Regards, Dmitry ___ notmuch mailing list notmuch@notmuchmail.org http://notmuchmail.org/mailman/listinfo/notmuch

[PATCH v2 1/4] test: add `notmuch-hello-mode-hook-counter'

2011-12-17 Thread Dmitry Kurochkin
Add `notmuch-hello-mode-hook-counter' hook to count how many times `notmuch-hello-mode-hook' was called. The counter function increments `notmuch-hello-mode-hook-counter' variable value if it is bount, otherwise it does nothing. --- test/test-lib.el |9 + 1 files changed, 9 insertions

[PATCH v2 2/4] test: add test for `notmuch-hello-mode-hook'

2011-12-17 Thread Dmitry Kurochkin
Test that `notmuch-hello-mode-hook' is called once when `notmuch-hello' function is called. --- test/emacs |9 + 1 files changed, 9 insertions(+), 0 deletions(-) diff --git a/test/emacs b/test/emacs index 6e922de..a864ffa 100755 --- a/test/emacs +++ b/test/emacs @@ -476,4 +476,13 @@ t

[PATCH v2 3/4] test: add broken test for `notmuch-hello-mode-hook' called during update

2011-12-17 Thread Dmitry Kurochkin
Test that `notmuch-hello-mode-hook' is not called during `notmuch-hello' buffer updates. The test is currently broken. --- test/emacs | 11 +++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/test/emacs b/test/emacs index a864ffa..b4c2444 100755 --- a/test/emacs +++ b/te

[PATCH v2 4/4] emacs: do not call `notmuch-hello-mode' on update

2011-12-17 Thread Dmitry Kurochkin
`notmuch-hello' should call `notmuch-hello-mode' function only when run for the first time. But before the change, `notmuch-hello' used `kill-all-local-variables' to remove editable widgets fields. This caused the major mode to be reset, and `notmuch-hello-mode' to be called every time. The patc

[PATCH v3 0/4] emacs: do not call `notmuch-hello-mode' on update

2011-12-17 Thread Dmitry Kurochkin
Changes: v3: * remove useless let with `widget-field-list', thanks Austin v2: * actually use `all' variable in `mapc' call, thanks Tomi ___ notmuch mailing list notmuch@notmuchmail.org http://notmuchmail.org/mailman/listinfo/notmuch

[PATCH v3 1/4] test: add `notmuch-hello-mode-hook-counter'

2011-12-17 Thread Dmitry Kurochkin
Add `notmuch-hello-mode-hook-counter' hook to count how many times `notmuch-hello-mode-hook' was called. The counter function increments `notmuch-hello-mode-hook-counter' variable value if it is bount, otherwise it does nothing. --- test/test-lib.el |9 + 1 files changed, 9 insertions

[PATCH v3 2/4] test: add test for `notmuch-hello-mode-hook'

2011-12-17 Thread Dmitry Kurochkin
Test that `notmuch-hello-mode-hook' is called once when `notmuch-hello' function is called. --- test/emacs |9 + 1 files changed, 9 insertions(+), 0 deletions(-) diff --git a/test/emacs b/test/emacs index 6e922de..a864ffa 100755 --- a/test/emacs +++ b/test/emacs @@ -476,4 +476,13 @@ t

[PATCH v3 3/4] test: add broken test for `notmuch-hello-mode-hook' called during update

2011-12-17 Thread Dmitry Kurochkin
Test that `notmuch-hello-mode-hook' is not called during `notmuch-hello' buffer updates. The test is currently broken. --- test/emacs | 11 +++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/test/emacs b/test/emacs index a864ffa..b4c2444 100755 --- a/test/emacs +++ b/te

[PATCH v3 4/4] emacs: do not call `notmuch-hello-mode' on update

2011-12-17 Thread Dmitry Kurochkin
`notmuch-hello' should call `notmuch-hello-mode' function only when run for the first time. But before the change, `notmuch-hello' used `kill-all-local-variables' to remove editable widgets fields. This caused the major mode to be reset, and `notmuch-hello-mode' to be called every time. The patc

[PATCH v4 0/4] emacs: do not call `notmuch-hello-mode' on update

2011-12-17 Thread Dmitry Kurochkin
Changes: v4: * explain why we need to properly delete editable widget fields v3: * remove useless let with `widget-field-list', thanks Austin v2: * actually use `all' variable in `mapc' call, thanks Tomi ___ notmuch mailing list notmuch@notmuchmail

[PATCH v4 1/4] test: add `notmuch-hello-mode-hook-counter'

2011-12-17 Thread Dmitry Kurochkin
Add `notmuch-hello-mode-hook-counter' hook to count how many times `notmuch-hello-mode-hook' was called. The counter function increments `notmuch-hello-mode-hook-counter' variable value if it is bount, otherwise it does nothing. --- test/test-lib.el |9 + 1 files changed, 9 insertions

[PATCH v4 2/4] test: add test for `notmuch-hello-mode-hook'

2011-12-17 Thread Dmitry Kurochkin
Test that `notmuch-hello-mode-hook' is called once when `notmuch-hello' function is called. --- test/emacs |9 + 1 files changed, 9 insertions(+), 0 deletions(-) diff --git a/test/emacs b/test/emacs index 6e922de..a864ffa 100755 --- a/test/emacs +++ b/test/emacs @@ -476,4 +476,13 @@ t

[PATCH v4 3/4] test: add broken test for `notmuch-hello-mode-hook' called during update

2011-12-17 Thread Dmitry Kurochkin
Test that `notmuch-hello-mode-hook' is not called during `notmuch-hello' buffer updates. The test is currently broken. --- test/emacs | 11 +++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/test/emacs b/test/emacs index a864ffa..b4c2444 100755 --- a/test/emacs +++ b/te

[PATCH v4 4/4] emacs: do not call `notmuch-hello-mode' on update

2011-12-17 Thread Dmitry Kurochkin
`notmuch-hello' should call `notmuch-hello-mode' function only when run for the first time. But before the change, `notmuch-hello' used `kill-all-local-variables' to remove editable widgets fields. This caused the major mode to be reset, and `notmuch-hello-mode' to be called every time. The patc

Re: Code Style Bikeshed 1/n: Break before Brace or Brace before Break?

2011-12-18 Thread Dmitry Kurochkin
+1 for the former. How about indenting with spaces+tabs vs indenting with spaces only? :) Regards, Dmitry ___ notmuch mailing list notmuch@notmuchmail.org http://notmuchmail.org/mailman/listinfo/notmuch

Re: Code Style Bikeshed 1/n: Break before Brace or Brace before Break?

2011-12-18 Thread Dmitry Kurochkin
On Sun, 18 Dec 2011 18:12:51 +0200, Tomi Ollila wrote: > On Sun, 18 Dec 2011 19:50:52 +0400, Dmitry Kurochkin > wrote: > > +1 for the former. > > +1 > > > How about indenting with spaces+tabs vs indenting with spaces only? :) > > -1 -- tab-width is 8, a

Re: [PATCH 1/2] test/smtp-dummy: add --background option for going background after listen(2)

2011-12-19 Thread Dmitry Kurochkin
Hi Tomi. On Tue, 13 Dec 2011 11:01:22 +0200, Tomi Ollila wrote: > To avoid the possibility that smtp-dummy doesn't have chance to bind > its listening socket until something tries to send message to it this > option makes caller wait until socket is already listening for connections. > > In case

Re: [PATCH] emacs: create patch filename from subject for inline patch fake parts

2011-12-20 Thread Dmitry Kurochkin
Hi Jani. On Tue, 20 Dec 2011 22:05:31 +0200, Jani Nikula wrote: > > Shameless promotion of own patches... I suppose not many use the > notmuch-wash-convert-inline-patch-to-part option, but with this patch > I've actually started to like it better. An actual patch name from > subject instead of "

Re: [PATCH] emacs: add notmuch-hello-refresh-hook

2011-12-20 Thread Dmitry Kurochkin
Hi Thomas. Looks good to me. We should also add tests for this, similar to those for `notmuch-hello-mode-hook'. Thomas, do you think you can work on it? Regards, Dmitry ___ notmuch mailing list notmuch@notmuchmail.org http://notmuchmail.org/mailman/

Re: [PATCH v3 3/4] emacs: rename notmuch-decimal-separator to notmuch-thousands-separator

2011-12-20 Thread Dmitry Kurochkin
Hi Thomas. On Wed, 21 Dec 2011 01:30:48 +0100, Thomas Jost wrote: > On Fri, 16 Dec 2011 16:34:03 +0400, Dmitry Kurochkin > wrote: > > On Fri, 16 Dec 2011 08:29:00 -0400, David Bremner wrote: > > > On Fri, 16 Dec 2011 04:59:22 +0400, Dmitry Kurochkin > > > w

Re: [PATCH 1/2] emacs: rename notmuch-decimal-separator to notmuch-hello-thousands-separator

2011-12-21 Thread Dmitry Kurochkin
Both patches look good to me. Thanks, Thomas! Regards, Dmitry ___ notmuch mailing list notmuch@notmuchmail.org http://notmuchmail.org/mailman/listinfo/notmuch

[PATCH 1/2] test: add general Emacs hook counter

2011-12-21 Thread Dmitry Kurochkin
Replace `notmuch-hello-mode-hook-counter' with general `hook-counter' and `add-hook-counter' functions to allow counting calls for any hook. --- test/test-lib.el | 21 + 1 files changed, 13 insertions(+), 8 deletions(-) diff --git a/test/test-lib.el b/test/test-lib.el index

[PATCH 2/2] test: add test for `notmuch-hello-refresh-hook'

2011-12-21 Thread Dmitry Kurochkin
Test that `notmuch-hello-refresh-hook' is called once when `notmuch-hello' is called and twice when calling `notmuch-hello-update' after that. The tests are very similar to tests for `notmuch-hello-mode-hook'. --- test/emacs | 19 +++ test/test-lib.el |1 + 2 files cha

Re: [PATCH] test: add tests for `notmuch-hello-refresh-hook'

2011-12-21 Thread Dmitry Kurochkin
Hi Thomas. I think all hook count tests must be consistent. We should either add hook counters in test-lib.el (like it is already done for `notmuch-hello-mode-hook') or use lambdas in individual test cases (like you did in the patch). I believe the former approach is better (that is why I used i

Re: [PATCH 2/2] test: add test for `notmuch-hello-refresh-hook'

2011-12-21 Thread Dmitry Kurochkin
On Wed, 21 Dec 2011 22:49:13 +0100, Thomas Jost wrote: > On Wed, 21 Dec 2011 22:18:26 +0400, Dmitry Kurochkin > wrote: > > Test that `notmuch-hello-refresh-hook' is called once when > > `notmuch-hello' is called and twice when calling > > `notmuch-hello-upda

[PATCH] emacs: put the last search on top of recent searches in notmuch-hello

2011-12-21 Thread Dmitry Kurochkin
Notmuch-hello stores a list of recent searches. Before the change, if a search from this list is repeated, the recent search list is not changed. The patch makes repeated recent searches move to the head of the list. I.e. the last search is always on top of the recent search list, which is what

Re: [RFC][PATCH] notmuch: Workaround to allow ignoring non-void function return.

2011-12-22 Thread Dmitry Kurochkin
Hi David. Perhaps I am missing something here. But I do not get any warnings when building with GCC 4.6.2 with -Wall -Werror (-O2 and -O0). I do not like adding any complex hacks to make the build warning-free on old GCC versions. If this happens on the build bot, we should just update it or ig

Re: [PATCH] emacs: fix off-by-one bug in notmuch-show-archive

2011-12-23 Thread Dmitry Kurochkin
Hi Aaron. Thanks for the fix. Would be nice to have a test for it :) Regards, Dmitry ___ notmuch mailing list notmuch@notmuchmail.org http://notmuchmail.org/mailman/listinfo/notmuch

Re: [PATCH] emacs: fix off-by-one bug in notmuch-show-archive

2011-12-23 Thread Dmitry Kurochkin
Hi Aaron. Thanks for the fix. Would be nice to have a test for it :) Regards, Dmitry ___ notmuch mailing list notmuch@notmuchmail.org http://notmuchmail.org/mailman/listinfo/notmuch

<    1   2   3   4   5   6   7   8   9   10   >