[notmuch] [PATCH] notmuch: Add hooks for show-mode and search-mode

Carl Worth cworth at cworth.org
Wed Nov 18 15:44:07 PST 2009


On Wed, 18 Nov 2009 20:44:58 +0530, aneesh.kumar at linux.vnet.ibm.com (Aneesh Kumar K.V) wrote:
> From: Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com>
> Date: Wed, 18 Nov 2009 20:43:13 +0530
> Subject: [PATCH] notmuch: Add hooks for show-mode and search-mode
> 
> This enables to do things like
> 
> (add-hook 'notmuch-search-mode-hook
>           (lambda()
>             (hl-line-mode 1) ))

Hi Aneesh,

Thanks for the patch. I think the hooks will be genuinely useful. I
haven't pushed this yet for two questions:

1. I recently merged an independent patch from Keith to add one hook
already. (And it looks like Keith got fancy and used defcustom instead
of defvar.) Could you re-do your patch on top of master and match the
style he used? [*]

2. If this hl-line-mode thing is interesting for you, might it not be
interesting for all users? (What does it do anyway?)

One concern I have with hooks is that people will use them to fix things
locally and prevent the defaults getting fixed to improve things for
everybody. (Granted, sometimes there's an honest difference of opinion,
so the defaults can't always satisfy everyone, and we'll want the
hooks.)

I guess I'm just hoping that people will at least attempt to get
improvements to be integrated into the defaults instead of just changing
local hooks.

-Carl

[*] Independently, it might be nice to switch all of our variables
intended to be tweaked by the user from defvar to defcustom.


More information about the notmuch mailing list