--- /dev/null
+Return-Path: <bremner@unb.ca>\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 E73D9431FAF\r
+ for <notmuch@notmuchmail.org>; Sun, 2 Sep 2012 06:54:29 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: 0\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none]\r
+ autolearn=disabled\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 BVoDaKNVnHuE for <notmuch@notmuchmail.org>;\r
+ Sun, 2 Sep 2012 06:54:28 -0700 (PDT)\r
+Received: from tesseract.cs.unb.ca (tesseract.cs.unb.ca [131.202.240.238])\r
+ (using TLSv1 with cipher AES256-SHA (256/256 bits))\r
+ (No client certificate requested)\r
+ by olra.theworths.org (Postfix) with ESMTPS id C5DED431FB6\r
+ for <notmuch@notmuchmail.org>; Sun, 2 Sep 2012 06:54:28 -0700 (PDT)\r
+Received: from fctnnbsc30w-156034089108.dhcp-dynamic.fibreop.nb.bellaliant.net\r
+ ([156.34.89.108] helo=zancas.localnet)\r
+ by tesseract.cs.unb.ca with esmtpsa\r
+ (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.72)\r
+ (envelope-from <bremner@unb.ca>)\r
+ id 1T8Ad1-00085J-Hh; Sun, 02 Sep 2012 10:54:23 -0300\r
+Received: from bremner by zancas.localnet with local (Exim 4.80)\r
+ (envelope-from <bremner@unb.ca>)\r
+ id 1T8Acw-0005YK-29; Sun, 02 Sep 2012 10:54:14 -0300\r
+From: David Bremner <david@tethera.net>\r
+To: Tomi Ollila <tomi.ollila@iki.fi>,\r
+ Mark Walters <markwalters1009@gmail.com>, notmuch@notmuchmail.org\r
+Subject: Re: [PATCH 1/5] emacs: compile and load notmuch-pick.el if present.\r
+In-Reply-To: <m2ipdcqjwj.fsf@guru.guru-group.fi>\r
+References: <1343164911-31589-1-git-send-email-markwalters1009@gmail.com>\r
+ <1343164911-31589-2-git-send-email-markwalters1009@gmail.com>\r
+ <m2ipdcqjwj.fsf@guru.guru-group.fi>\r
+User-Agent: Notmuch/0.14 (http://notmuchmail.org) Emacs/24.1.1\r
+ (x86_64-pc-linux-gnu)\r
+Date: Sun, 02 Sep 2012 10:54:13 -0300\r
+Message-ID: <87y5ks7coq.fsf@zancas.localnet>\r
+MIME-Version: 1.0\r
+Content-Type: text/plain\r
+X-Spam_bar: -\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: Sun, 02 Sep 2012 13:54:30 -0000\r
+\r
+Tomi Ollila <tomi.ollila@iki.fi> writes:\r
+> I think it would be better to provide a shell script in \r
+> notmuch-pick directory which byte-compiles and installs notmuch-pick\r
+> in case user wants to install/update notmuch-pick. Whenever notmuch-pick\r
+> is good enough to be shipped inside $(dir) above then the aboce conditional\r
+> is not needed (at all).\r
+\r
+I just tried notmuch-pick for the first time, and at least on this\r
+relatively beefy machine, it runs fine uncompiled. \r
+\r
+I'm not sure if it is worth complicating the mainline install. Which\r
+means I guess I am agreeing with Tomi. It could also be in independant\r
+Makefile rather than a script.\r
+\r
+I don't think it's crucial to install notmuch-pick into the main lisp\r
+context of (Debian) packaging I don't think that will work very well.\r
+The way org-mode works is that it ships a seperate contrib lisp\r
+directory; on Debian this is in /usr/share/org-mode/contrib. Then people\r
+who want to use a contrib piece of lisp would just add the following to\r
+their .emacs:\r
+\r
+(add-to-list 'load-path "/usr/share/notmuch/contrib/emacs-lisp")\r
+(require 'notmuch-pick)\r
+\r
+at least given the changes that Tomi proposes below.\r
+The path is obviously just an example.\r
+\r
+> (require 'notmuch-hello)\r
+> (require 'notmuch-show)\r
+> (require 'notmuch) ;; XXX ATM, as notmuch-search-mode-map is defined here\r
+>\r
+> And, at the end, before (provide 'notmuch-pick), execute the lines\r
+> what currenty are contained in (notmuch-pick-init).\r
+\r
+Yes, this sounds about right to me. require should also take care of the\r
+"only run this once" part.\r
+\r
+FWIW, I'm currently running pick from the source tree as:\r
+\r
+(add-to-list 'load-path\r
+ (expand-file-name "~/blah"))\r
+(when (locate-library "notmuch-pick")\r
+ (eval-after-load 'notmuch\r
+ '(progn \r
+ (require 'notmuch-pick)\r
+ (notmuch-pick-init))))\r
+\r
+it's a bit overengineered, but this way it doesn't crap out on machines\r
+where notmuch-pick is not installed.\r