unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
From: David Edmondson <dme@dme.org>
To: Carl Worth <cworth@cworth.org>, notmuch@notmuchmail.org
Subject: Re: [PATCH] emacs: Add notmuch-hello.el, a friendly frontend to notmuch
Date: Mon, 26 Apr 2010 10:36:28 +0100	[thread overview]
Message-ID: <87ljcaimhv.fsf@ut.hh.sledj.net> (raw)
In-Reply-To: <87iq7i2aia.fsf@yoom.home.cworth.org>

On Fri, 23 Apr 2010 13:13:01 -0700, Carl Worth <cworth@cworth.org> wrote:
>   * This should be integrated such that (require 'notmuch) provides the
>     notmuch-hello functionality. That's our documented access point for
>     getting at notmuch functionality.

I'll do this, but I wonder if it is actually good advice. It causes
notmuch.el (and anything that requires) to be loaded immediately. This
will typically happen before any of a users' customisation settings are
loaded (as `custom-set-variables', etc. generally happens right at the
bottom of .emacs).

A result of this is that notmuch can't use any of the customisation
settings to adapt its' behaviour at load time. A example is (about which
more lower down):

>   * I would *love* a simple way to import my existing notmuch-folder
>     configuration into notmuch-hello. Bonus points if this happens
>     automatically.

notmuch-hello.el has:

(defcustom notmuch-hello-saved-searches notmuch-folders
  "A list of saved searches to display."
  :type '(alist :key-type string :value-type string)
  :group 'notmuch)

So if `notmuch-folders' is set before notmuch-hello.el is loaded, you
get some saved-searches copied from your folders (but this won't
override any specific settings you made for
`notmuch-hello-saved-searches').

Relying on the order in general is bad
(cf. `notmuch-search-authors-width'), but it can allow us to provide
some useful functionality.

If we don't want users to "(require 'notmuch)" we'd probably have to
suggest one or more autoloads - perhaps even provide a file with a bunch
of autoloads in it. Oh, or "(require 'notmuch)" should just load
something that has the autoloads (d'oh!) and some
`define-mail-user-agent' goop so that `compose-mail' does the right
thing.

I'll try to produce a patch for this last thing.

>   * The logo background is gray on my white-background emacs. That
>     looks odd.

Patch sent.

>   * It would be great if point were in the search bar right when this
>     mode started.

This is customisable, and I see that you changed the default ;-)

>   * I'd like the saved searches to appear before the recent searches I
>     think.

Did you come to any conclusion about this?

>   * I'm not sure how useful the numbered shortcuts are for the recent
>     searches. We want to encourage people to move to saved searches
>     instead, (and the recent searches are quite transient anyway). So do
>     we really need these? [I mistook them for message counts at
>     first.]

Patch sent which removes them.

>   * Repeating a recent search by pressing RET on it creates a new
>     identical search which doesn't seem all that useful.

Patch sent.

>   * I would *love* a simple way to import my existing notmuch-folder
>     configuration into notmuch-hello. Bonus points if this happens
>     automatically.

We could have `notmuch-hello' use `notmuch-folders' if
`notmuch-hello-saved-searches' is `nil'. Would that help?

> Finally, I'm quite inclined to make `notmuch' invoke this mode, so
> think about that.

It seems straightforward, I'll produce a patch.

dme.
-- 
David Edmondson, http://dme.org

  parent reply	other threads:[~2010-04-26  9:36 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-16 20:32 Opening the merge window for 0.3 Carl Worth
2010-04-22  1:11 ` Update on 0.3 progress Carl Worth
2010-04-22  2:49   ` Dirk Hohndel
2010-04-22  6:10   ` Jesse Rosenthal
2010-04-22  8:27   ` [PATCH] emacs: Add notmuch-hello.el, a friendly frontend to notmuch David Edmondson
2010-04-23 20:13     ` Carl Worth
2010-04-23 22:49       ` Carl Worth
2010-04-24 12:31       ` Ideas for making notmuch-hello easier to navigate Carl Worth
2010-04-26  9:25       ` [PATCH 1/3] emacs: Adapt the logo background colour to that of the frame David Edmondson
2010-04-26  9:25       ` [PATCH 2/3] emacs: Remove the accelerator keys from the hello buffer David Edmondson
2010-04-26  9:25       ` [PATCH 3/3] emacs: Add a search to the 'recent searches' list once only David Edmondson
2010-04-26  9:36       ` David Edmondson [this message]
2010-04-26 14:59         ` [PATCH] emacs: Add notmuch-hello.el, a friendly frontend to notmuch Carl Worth
2010-04-26 17:16           ` Carl Worth
2010-04-26 17:38             ` Jameson Rollins
2010-04-26 18:03               ` David Edmondson
2010-04-26 18:38                 ` Carl Worth
2010-04-26 15:07       ` David Edmondson
  -- strict thread matches above, loose matches on Subject: below --
2010-04-12 10:13 David Edmondson
2010-04-13  4:58 ` Xavier Maillard
2010-04-13  6:54   ` David Edmondson
2010-04-13 10:25 ` Michal Sojka
2010-04-13 10:33   ` David Edmondson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://notmuchmail.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87ljcaimhv.fsf@ut.hh.sledj.net \
    --to=dme@dme.org \
    --cc=cworth@cworth.org \
    --cc=notmuch@notmuchmail.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).