Re: [PATCH v2 0/3] emacs: Document notmuch-show-get-message-properties

2011-12-16 Thread Jameson Graef Rollins
On Fri, 16 Dec 2011 09:01:21 -0400, David Bremner da...@tethera.net wrote:
 The others are (not too surprisingly) stale and need rebasing. I'm also
 not clear on whether we have concensus on whether the patches are
 suitable for inclusion, so feedback from others would be welcome
 (perhaps before Daniel goes to the trouble of rebasing).

I definitely like the idea of thread outlining, but this isn't quite the
implementation that I would personally like to see.  What I would like
requires a bunch of changes to notmuch show, though.  This looks like it
could be kind of interesting to me in the interim, though, and it's not
particular invasive, so if Daniel want's to rebase it I see no problem.

jamie.


pgpbCNWj0krLX.pgp
Description: PGP signature
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


[RFC PATCH v2 0/3] lib/cli/emacs: limit number of messages in search results

2011-11-04 Thread Austin Clements
On Mon, Oct 31, 2011 at 6:07 PM, Jani Nikula  wrote:
> On Mon, 31 Oct 2011 14:44:29 -0700, Jameson Graef Rollins  finestructure.net> wrote:
>> In order to push forward with this, though, I think we really need to
>> have a complete unit test for this new functionality. ?We usually like
>> to see units tests that describe and then test for the new functionality
>> you wish to add, followed by the patches that provide the new
>> functionality. ?Lots of good tests for new functionality being proposed
>> here shouldn't be too difficult to work out ahead of time.
>
> Right. I'd just like to make sure the approach I've taken (particularly
> patch 1 in the set as it touches the lib) is acceptable before spending
> time on testing and documentation etc. Indeed patches 1 and 2 changed
> fundamentally between v1 and v2 after some chats on IRC. If the comments
> now are favourable, I'll write the tests and documentation. (Though I
> guess I have to admit the tests would've been beneficial to me already
> now...)

The library interface looks perfectly reasonable and consistent to me.
 My only concern would be that there's no way to return errors from
notmuch_query_count_threads, but notmuch_query_count_messages has
exactly the same problem.

Other than that, you missed a few spaces before parentheses.


Re: [RFC PATCH v2 0/3] lib/cli/emacs: limit number of messages in search results

2011-11-04 Thread Austin Clements
On Mon, Oct 31, 2011 at 6:07 PM, Jani Nikula j...@nikula.org wrote:
 On Mon, 31 Oct 2011 14:44:29 -0700, Jameson Graef Rollins 
 jroll...@finestructure.net wrote:
 In order to push forward with this, though, I think we really need to
 have a complete unit test for this new functionality.  We usually like
 to see units tests that describe and then test for the new functionality
 you wish to add, followed by the patches that provide the new
 functionality.  Lots of good tests for new functionality being proposed
 here shouldn't be too difficult to work out ahead of time.

 Right. I'd just like to make sure the approach I've taken (particularly
 patch 1 in the set as it touches the lib) is acceptable before spending
 time on testing and documentation etc. Indeed patches 1 and 2 changed
 fundamentally between v1 and v2 after some chats on IRC. If the comments
 now are favourable, I'll write the tests and documentation. (Though I
 guess I have to admit the tests would've been beneficial to me already
 now...)

The library interface looks perfectly reasonable and consistent to me.
 My only concern would be that there's no way to return errors from
notmuch_query_count_threads, but notmuch_query_count_messages has
exactly the same problem.

Other than that, you missed a few spaces before parentheses.
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


[RFC PATCH v2 0/3] lib/cli/emacs: limit number of messages in search results

2011-11-02 Thread Jani Nikula
On Tue, 01 Nov 2011 09:30:56 -0300, David Bremner  wrote:
> Is just because it add a function to the library that you think this
> might be problematic?  I don't think we are super-dogmatic about the
> library never growing.  When notmuch started, there were no bindings, so
> in retrospect maybe more functionality went into the CLI than might
> happen if we started from scratch. If I remember Carl's statement
> correctly, one rule is that stuff in the library should not require
> configuration.

Hi, thanks, that's encouraging. It's mostly that, based on past
experience, I'm hesitant about extending a library interface. Once you
get users, you have to live with it. So you want to get it right.

Having said that, I think in this v2 of the set, the library interface
for notmuch_query_count_threads() is sane and complimentary to the
existing notmuch_query_count_messages(). (Also quoting IRC: "
j4ni: Yes, the interface seems totally reasonable.") Later on, someone
might come up with a better implementation, but for now it's already
much better than having to iterate and construct the threads.

I'll prepare a v3 with some tests and polish.

BR,
Jani.


Re: [RFC PATCH v2 0/3] lib/cli/emacs: limit number of messages in search results

2011-11-02 Thread Jani Nikula
On Tue, 01 Nov 2011 09:30:56 -0300, David Bremner da...@tethera.net wrote:
 Is just because it add a function to the library that you think this
 might be problematic?  I don't think we are super-dogmatic about the
 library never growing.  When notmuch started, there were no bindings, so
 in retrospect maybe more functionality went into the CLI than might
 happen if we started from scratch. If I remember Carl's statement
 correctly, one rule is that stuff in the library should not require
 configuration.

Hi, thanks, that's encouraging. It's mostly that, based on past
experience, I'm hesitant about extending a library interface. Once you
get users, you have to live with it. So you want to get it right.

Having said that, I think in this v2 of the set, the library interface
for notmuch_query_count_threads() is sane and complimentary to the
existing notmuch_query_count_messages(). (Also quoting IRC: amdragon
j4ni: Yes, the interface seems totally reasonable.) Later on, someone
might come up with a better implementation, but for now it's already
much better than having to iterate and construct the threads.

I'll prepare a v3 with some tests and polish.

BR,
Jani.
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


[RFC PATCH v2 0/3] lib/cli/emacs: limit number of messages in search results

2011-11-01 Thread David Bremner
On Mon, 31 Oct 2011 23:18:07 +0200, Jani Nikula  wrote:
> 
> I'm still marking it as RFC. It works for me, but patch 1 might be deemed
> unacceptable.
> 

Hi Jani;

Is just because it add a function to the library that you think this
might be problematic?  I don't think we are super-dogmatic about the
library never growing.  When notmuch started, there were no bindings, so
in retrospect maybe more functionality went into the CLI than might
happen if we started from scratch. If I remember Carl's statement
correctly, one rule is that stuff in the library should not require
configuration.

Just my personal view,

David


[RFC PATCH v2 0/3] lib/cli/emacs: limit number of messages in search results

2011-11-01 Thread Jani Nikula
On Mon, 31 Oct 2011 14:44:29 -0700, Jameson Graef Rollins  wrote:
> Hi, Jani.  Thanks for working on this.  This should also be valuable for
> vim users.

Thanks for your interest! :)

> In order to push forward with this, though, I think we really need to
> have a complete unit test for this new functionality.  We usually like
> to see units tests that describe and then test for the new functionality
> you wish to add, followed by the patches that provide the new
> functionality.  Lots of good tests for new functionality being proposed
> here shouldn't be too difficult to work out ahead of time.

Right. I'd just like to make sure the approach I've taken (particularly
patch 1 in the set as it touches the lib) is acceptable before spending
time on testing and documentation etc. Indeed patches 1 and 2 changed
fundamentally between v1 and v2 after some chats on IRC. If the comments
now are favourable, I'll write the tests and documentation. (Though I
guess I have to admit the tests would've been beneficial to me already
now...)

BR,
Jani.


[RFC PATCH v2 0/3] lib/cli/emacs: limit number of messages in search results

2011-11-01 Thread Jani Nikula
Hi, this is an iteration of id:"cover.1319833617.git.jani at nikula.org" 
addressing
comments on the list and IRC. Main changes:

* Results are now limited based on threads (not messages) for thread and summary
  output. This is accomplished with a new lib function to count the number of
  threads in matching messages.

* cli part is now inspired by James Vasile's patch
  id:"8739gyw0zh.fsf at opensourcematters.org", with the additional ability to
  limit from the end of result set.

* Bugs reported by Daniel Schoepe fixed.

* Don't show buttons if everything is visible already.

I'm still marking it as RFC. It works for me, but patch 1 might be deemed
unacceptable.


BR,
Jani.


Jani Nikula (3):
  lib: add function to get the number of threads matching a search
  cli: add options --first and --maxitems to notmuch search
  emacs: support limiting the number of results shown in search results

 emacs/notmuch-hello.el |   17 ++--
 emacs/notmuch.el   |   53 ++---
 lib/notmuch.h  |   14 ++
 lib/query.cc   |   40 
 notmuch-search.c   |   67 +++
 5 files changed, 171 insertions(+), 20 deletions(-)

-- 
1.7.5.4



Re: [RFC PATCH v2 0/3] lib/cli/emacs: limit number of messages in search results

2011-11-01 Thread David Bremner
On Mon, 31 Oct 2011 23:18:07 +0200, Jani Nikula j...@nikula.org wrote:
 
 I'm still marking it as RFC. It works for me, but patch 1 might be deemed
 unacceptable.
 

Hi Jani;

Is just because it add a function to the library that you think this
might be problematic?  I don't think we are super-dogmatic about the
library never growing.  When notmuch started, there were no bindings, so
in retrospect maybe more functionality went into the CLI than might
happen if we started from scratch. If I remember Carl's statement
correctly, one rule is that stuff in the library should not require
configuration.

Just my personal view,

David
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


[RFC PATCH v2 0/3] lib/cli/emacs: limit number of messages in search results

2011-10-31 Thread Jameson Graef Rollins
On Tue, 01 Nov 2011 00:07:59 +0200, Jani Nikula  wrote:
> On Mon, 31 Oct 2011 14:44:29 -0700, Jameson Graef Rollins  finestructure.net> wrote:
> Right. I'd just like to make sure the approach I've taken (particularly
> patch 1 in the set as it touches the lib) is acceptable before spending
> time on testing and documentation etc. Indeed patches 1 and 2 changed
> fundamentally between v1 and v2 after some chats on IRC. If the comments
> now are favourable, I'll write the tests and documentation. (Though I
> guess I have to admit the tests would've been beneficial to me already
> now...)

I would say that since this is functionality that we do eventually want,
a known_broken test suite that tests for the functionality we want to
see would be very useful right from the start, even before any patches
to supply the functionality are made.  With the tests in hand we can
iterate over exactly what we want the ui to provide, and then worry
about the specific implementation.

The documentation can come later with the actual feature patches.

jamie.
-- next part --
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 835 bytes
Desc: not available
URL: 



[RFC PATCH v2 0/3] lib/cli/emacs: limit number of messages in search results

2011-10-31 Thread Jameson Graef Rollins
On Mon, 31 Oct 2011 23:18:07 +0200, Jani Nikula  wrote:
> Hi, this is an iteration of id:"cover.1319833617.git.jani at nikula.org" 
> addressing
> comments on the list and IRC. Main changes:
> 
> * Results are now limited based on threads (not messages) for thread and 
> summary
>   output. This is accomplished with a new lib function to count the number of
>   threads in matching messages.
> 
> * cli part is now inspired by James Vasile's patch
>   id:"8739gyw0zh.fsf at opensourcematters.org", with the additional ability to
>   limit from the end of result set.
> 
> * Bugs reported by Daniel Schoepe fixed.
> 
> * Don't show buttons if everything is visible already.
> 
> I'm still marking it as RFC. It works for me, but patch 1 might be deemed
> unacceptable.

Hi, Jani.  Thanks for working on this.  This should also be valuable for
vim users.

In order to push forward with this, though, I think we really need to
have a complete unit test for this new functionality.  We usually like
to see units tests that describe and then test for the new functionality
you wish to add, followed by the patches that provide the new
functionality.  Lots of good tests for new functionality being proposed
here shouldn't be too difficult to work out ahead of time.

For instance, here's an example of a test that I would like to see:

test_begin_subtest "maxitems does the right thing"
notmuch search tag:foo | head -n 20 >expected
notmuch search --maxitems=20 tag:foo >output
test_expect_equal_file expected output

test_begin_subtest "concatenation of limited searches does the right thing"
notmuch search tag:foo | head -n 20 >expected
notmuch search --maxitems=10 tag:foo >output
notmuch search --maxitems=10 --first=10 tag:foo >>output
test_expect_equal_file expected output


jamie.
-- next part --
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 835 bytes
Desc: not available
URL: 



[RFC PATCH v2 0/3] lib/cli/emacs: limit number of messages in search results

2011-10-31 Thread Jani Nikula
Hi, this is an iteration of id:cover.1319833617.git.j...@nikula.org addressing
comments on the list and IRC. Main changes:

* Results are now limited based on threads (not messages) for thread and summary
  output. This is accomplished with a new lib function to count the number of
  threads in matching messages.

* cli part is now inspired by James Vasile's patch
  id:8739gyw0zh@opensourcematters.org, with the additional ability to
  limit from the end of result set.

* Bugs reported by Daniel Schoepe fixed.

* Don't show buttons if everything is visible already.

I'm still marking it as RFC. It works for me, but patch 1 might be deemed
unacceptable.


BR,
Jani.


Jani Nikula (3):
  lib: add function to get the number of threads matching a search
  cli: add options --first and --maxitems to notmuch search
  emacs: support limiting the number of results shown in search results

 emacs/notmuch-hello.el |   17 ++--
 emacs/notmuch.el   |   53 ++---
 lib/notmuch.h  |   14 ++
 lib/query.cc   |   40 
 notmuch-search.c   |   67 +++
 5 files changed, 171 insertions(+), 20 deletions(-)

-- 
1.7.5.4

___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


Re: [RFC PATCH v2 0/3] lib/cli/emacs: limit number of messages in search results

2011-10-31 Thread Jameson Graef Rollins
On Tue, 01 Nov 2011 00:07:59 +0200, Jani Nikula j...@nikula.org wrote:
 On Mon, 31 Oct 2011 14:44:29 -0700, Jameson Graef Rollins 
 jroll...@finestructure.net wrote:
 Right. I'd just like to make sure the approach I've taken (particularly
 patch 1 in the set as it touches the lib) is acceptable before spending
 time on testing and documentation etc. Indeed patches 1 and 2 changed
 fundamentally between v1 and v2 after some chats on IRC. If the comments
 now are favourable, I'll write the tests and documentation. (Though I
 guess I have to admit the tests would've been beneficial to me already
 now...)

I would say that since this is functionality that we do eventually want,
a known_broken test suite that tests for the functionality we want to
see would be very useful right from the start, even before any patches
to supply the functionality are made.  With the tests in hand we can
iterate over exactly what we want the ui to provide, and then worry
about the specific implementation.

The documentation can come later with the actual feature patches.

jamie.


pgpvHaBzQPqjo.pgp
Description: PGP signature
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


[PATCH v2 0/3] improved broken tests support and test for a bug

2011-09-10 Thread David Bremner
On Mon,  4 Jul 2011 08:07:18 +0400, Dmitry Kurochkin  wrote:
> This version implements suggestions by Austin.
> 
> Regards,
>   Dmitry

I have pushed this series. 


Re: [PATCH v2 0/3] improved broken tests support and test for a bug

2011-09-10 Thread David Bremner
On Mon,  4 Jul 2011 08:07:18 +0400, Dmitry Kurochkin 
dmitry.kuroch...@gmail.com wrote:
 This version implements suggestions by Austin.
 
 Regards,
   Dmitry

I have pushed this series. 
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


[PATCH v2 0/3] emacs: Document notmuch-show-get-message-properties

2011-07-08 Thread Daniel Schoepe
This version fixes the issues mentioned by Austin and highlights the currently
displayed message in the outline buffer. My previous issues with 'point-entered
and 'point-left were caused by linum-mode, so don't enable it for notmuch-show 
buffers.

I haven't had time yet to implement a more sophisticated thread
structure display as suggested in
id:"87y613vpi6.fsf at servo.factory.finestructure.net" though.



[PATCH v2 0/3] emacs: Document notmuch-show-get-message-properties

2011-07-08 Thread Daniel Schoepe
This version fixes the issues mentioned by Austin and highlights the currently
displayed message in the outline buffer. My previous issues with 'point-entered
and 'point-left were caused by linum-mode, so don't enable it for notmuch-show 
buffers.

I haven't had time yet to implement a more sophisticated thread
structure display as suggested in
id:87y613vpi6@servo.factory.finestructure.net though.

___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


[PATCH v2 0/3] improved broken tests support and test for a bug

2011-07-04 Thread Dmitry Kurochkin
This version implements suggestions by Austin.

Regards,
  Dmitry


[PATCH v2 0/3] improved broken tests support and test for a bug

2011-07-03 Thread Dmitry Kurochkin
This version implements suggestions by Austin.

Regards,
  Dmitry
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


[PATCH v2 0/3] Implement reply to sender

2011-05-27 Thread Mark Walters
Many thanks for the rapid response: I have modified the
patches as suggested and this version includes the
necessary documentation changes. I have also modified the
emacs portion to apply to current master.

Best wishes

Mark


These patches implement a reply to sender function.

On the command line this is done via a new option
to notmuch-reply: --reply-to=(sender|all) with all being
the default (as suggested).

In emacs it is bound to the key R. (Note it does not touch the
reply to thread command from notmuch-search: it is unclear to me
what reply to sender would mean there.)

Mark Walters (3):
  Adds the option "--reply-to" to notmuch reply.
  Documentation changes for --reply-to= option to notmuch reply.
  Emacs changes for reply to sender

 emacs/notmuch-mua.el  |   10 ++
 emacs/notmuch-show.el |8 +++-
 emacs/notmuch.el  |2 +-
 notmuch-reply.c   |   46 +++---
 notmuch.1 |   13 +
 notmuch.c |   10 ++
 6 files changed, 72 insertions(+), 17 deletions(-)

-- 
1.7.2.5



[PATCH v2 0/3] Implement reply to sender

2011-05-26 Thread Mark Walters
Many thanks for the rapid response: I have modified the
patches as suggested and this version includes the
necessary documentation changes. I have also modified the
emacs portion to apply to current master.

Best wishes

Mark


These patches implement a reply to sender function.

On the command line this is done via a new option
to notmuch-reply: --reply-to=(sender|all) with all being
the default (as suggested).

In emacs it is bound to the key R. (Note it does not touch the
reply to thread command from notmuch-search: it is unclear to me
what reply to sender would mean there.)

Mark Walters (3):
  Adds the option --reply-to to notmuch reply.
  Documentation changes for --reply-to= option to notmuch reply.
  Emacs changes for reply to sender

 emacs/notmuch-mua.el  |   10 ++
 emacs/notmuch-show.el |8 +++-
 emacs/notmuch.el  |2 +-
 notmuch-reply.c   |   46 +++---
 notmuch.1 |   13 +
 notmuch.c |   10 ++
 6 files changed, 72 insertions(+), 17 deletions(-)

-- 
1.7.2.5

___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


<    1   2