Re: [PATCH] emacs: Add notmuch-hello.el, a friendly frontend to notmuch
authorDavid Edmondson <dme@dme.org>
Mon, 26 Apr 2010 09:36:28 +0000 (10:36 +0100)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:36:53 +0000 (09:36 -0800)
30/7d7561db64c23acd8e32738eec9f1dd6d439f5 [new file with mode: 0644]

diff --git a/30/7d7561db64c23acd8e32738eec9f1dd6d439f5 b/30/7d7561db64c23acd8e32738eec9f1dd6d439f5
new file mode 100644 (file)
index 0000000..ffa1ea0
--- /dev/null
@@ -0,0 +1,145 @@
+Return-Path: <dme@dme.org>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+       by olra.theworths.org (Postfix) with ESMTP id 8E5CD4196F2\r
+       for <notmuch@notmuchmail.org>; Mon, 26 Apr 2010 02:36:56 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -1.9\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-1.9 tagged_above=-999 required=5\r
+       tests=[BAYES_00=-1.9] autolearn=ham\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+       by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+       with ESMTP id FcO8LLk8yI98 for <notmuch@notmuchmail.org>;\r
+       Mon, 26 Apr 2010 02:36:55 -0700 (PDT)\r
+Received: from mail-ww0-f53.google.com (mail-ww0-f53.google.com\r
+ [74.125.82.53])       by olra.theworths.org (Postfix) with ESMTP id CCE5D431FC1       for\r
+ <notmuch@notmuchmail.org>; Mon, 26 Apr 2010 02:36:54 -0700 (PDT)\r
+Received: by wwi18 with SMTP id 18so283703wwi.26\r
+       for <notmuch@notmuchmail.org>; Mon, 26 Apr 2010 02:36:54 -0700 (PDT)\r
+Received: by 10.216.86.82 with SMTP id v60mr2960wee.180.1272274579884;\r
+       Mon, 26 Apr 2010 02:36:19 -0700 (PDT)\r
+Received: from ut.hh.sledj.net (host83-217-165-81.dsl.vispa.com\r
+       [83.217.165.81])\r
+       by mx.google.com with ESMTPS id x1sm20474253wbx.13.2010.04.26.02.36.17\r
+       (version=TLSv1/SSLv3 cipher=RC4-MD5);\r
+       Mon, 26 Apr 2010 02:36:18 -0700 (PDT)\r
+Received: by ut.hh.sledj.net (Postfix, from userid 1000)\r
+       id 7DBB7594135; Mon, 26 Apr 2010 10:36:28 +0100 (BST)\r
+To: Carl Worth <cworth@cworth.org>, notmuch@notmuchmail.org\r
+Subject: Re: [PATCH] emacs: Add notmuch-hello.el,\r
+       a friendly frontend to notmuch\r
+In-Reply-To: <87iq7i2aia.fsf@yoom.home.cworth.org>\r
+References: <87y6gguw99.fsf@yoom.home.cworth.org>\r
+       <1271924853-8183-1-git-send-email-dme@dme.org>\r
+       <87iq7i2aia.fsf@yoom.home.cworth.org>\r
+User-Agent: Notmuch/0.2-187-g7c5f017 (http://notmuchmail.org) Emacs/23.1.1\r
+       (x86_64-pc-linux-gnu)\r
+From: David Edmondson <dme@dme.org>\r
+Date: Mon, 26 Apr 2010 10:36:28 +0100\r
+Message-ID: <87ljcaimhv.fsf@ut.hh.sledj.net>\r
+MIME-Version: 1.0\r
+Content-Type: text/plain; charset=us-ascii\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+       <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Mon, 26 Apr 2010 09:36:56 -0000\r
+\r
+On Fri, 23 Apr 2010 13:13:01 -0700, Carl Worth <cworth@cworth.org> wrote:\r
+>   * This should be integrated such that (require 'notmuch) provides the\r
+>     notmuch-hello functionality. That's our documented access point for\r
+>     getting at notmuch functionality.\r
+\r
+I'll do this, but I wonder if it is actually good advice. It causes\r
+notmuch.el (and anything that requires) to be loaded immediately. This\r
+will typically happen before any of a users' customisation settings are\r
+loaded (as `custom-set-variables', etc. generally happens right at the\r
+bottom of .emacs).\r
+\r
+A result of this is that notmuch can't use any of the customisation\r
+settings to adapt its' behaviour at load time. A example is (about which\r
+more lower down):\r
+\r
+>   * I would *love* a simple way to import my existing notmuch-folder\r
+>     configuration into notmuch-hello. Bonus points if this happens\r
+>     automatically.\r
+\r
+notmuch-hello.el has:\r
+\r
+(defcustom notmuch-hello-saved-searches notmuch-folders\r
+  "A list of saved searches to display."\r
+  :type '(alist :key-type string :value-type string)\r
+  :group 'notmuch)\r
+\r
+So if `notmuch-folders' is set before notmuch-hello.el is loaded, you\r
+get some saved-searches copied from your folders (but this won't\r
+override any specific settings you made for\r
+`notmuch-hello-saved-searches').\r
+\r
+Relying on the order in general is bad\r
+(cf. `notmuch-search-authors-width'), but it can allow us to provide\r
+some useful functionality.\r
+\r
+If we don't want users to "(require 'notmuch)" we'd probably have to\r
+suggest one or more autoloads - perhaps even provide a file with a bunch\r
+of autoloads in it. Oh, or "(require 'notmuch)" should just load\r
+something that has the autoloads (d'oh!) and some\r
+`define-mail-user-agent' goop so that `compose-mail' does the right\r
+thing.\r
+\r
+I'll try to produce a patch for this last thing.\r
+\r
+>   * The logo background is gray on my white-background emacs. That\r
+>     looks odd.\r
+\r
+Patch sent.\r
+\r
+>   * It would be great if point were in the search bar right when this\r
+>     mode started.\r
+\r
+This is customisable, and I see that you changed the default ;-)\r
+\r
+>   * I'd like the saved searches to appear before the recent searches I\r
+>     think.\r
+\r
+Did you come to any conclusion about this?\r
+\r
+>   * I'm not sure how useful the numbered shortcuts are for the recent\r
+>     searches. We want to encourage people to move to saved searches\r
+>     instead, (and the recent searches are quite transient anyway). So do\r
+>     we really need these? [I mistook them for message counts at\r
+>     first.]\r
+\r
+Patch sent which removes them.\r
+\r
+>   * Repeating a recent search by pressing RET on it creates a new\r
+>     identical search which doesn't seem all that useful.\r
+\r
+Patch sent.\r
+\r
+>   * I would *love* a simple way to import my existing notmuch-folder\r
+>     configuration into notmuch-hello. Bonus points if this happens\r
+>     automatically.\r
+\r
+We could have `notmuch-hello' use `notmuch-folders' if\r
+`notmuch-hello-saved-searches' is `nil'. Would that help?\r
+\r
+> Finally, I'm quite inclined to make `notmuch' invoke this mode, so\r
+> think about that.\r
+\r
+It seems straightforward, I'll produce a patch.\r
+\r
+dme.\r
+-- \r
+David Edmondson, http://dme.org\r