[PATCH 1/2] contrib: pick: remove sync parser
authorMark Walters <markwalters1009@gmail.com>
Mon, 26 Aug 2013 19:57:22 +0000 (20:57 +0100)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:56:40 +0000 (09:56 -0800)
9e/ae6faf31afd851b5e7c859520bd5d0676f642c [new file with mode: 0644]

diff --git a/9e/ae6faf31afd851b5e7c859520bd5d0676f642c b/9e/ae6faf31afd851b5e7c859520bd5d0676f642c
new file mode 100644 (file)
index 0000000..403989e
--- /dev/null
@@ -0,0 +1,127 @@
+Return-Path: <markwalters1009@gmail.com>\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 07C90431FDC\r
+       for <notmuch@notmuchmail.org>; Mon, 26 Aug 2013 12:57:37 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: 0.201\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=0.201 tagged_above=-999 required=5\r
+       tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,\r
+       FREEMAIL_ENVFROM_END_DIGIT=1, FREEMAIL_FROM=0.001,\r
+       RCVD_IN_DNSWL_LOW=-0.7] 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 T8MRLgXCK1K7 for <notmuch@notmuchmail.org>;\r
+       Mon, 26 Aug 2013 12:57:31 -0700 (PDT)\r
+Received: from mail-we0-f172.google.com (mail-we0-f172.google.com\r
+       [74.125.82.172]) (using TLSv1 with cipher RC4-SHA (128/128 bits))\r
+       (No client certificate requested)\r
+       by olra.theworths.org (Postfix) with ESMTPS id 5D663431FD4\r
+       for <notmuch@notmuchmail.org>; Mon, 26 Aug 2013 12:57:31 -0700 (PDT)\r
+Received: by mail-we0-f172.google.com with SMTP id t60so3106632wes.17\r
+       for <notmuch@notmuchmail.org>; Mon, 26 Aug 2013 12:57:30 -0700 (PDT)\r
+DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;\r
+       h=from:to:cc:subject:date:message-id:in-reply-to:references;\r
+       bh=CmHzUJdg5ZBIo+pOnnddlDrDdHXzrhG74ixLgfTxc78=;\r
+       b=t22fnuf1EgkZ3AN5OV6NhyHFPCaQIGke95KtuJXYc3yPV6NKooI6VOFWNZ9nOrobyF\r
+       dWdDQDvydie7uh5F4egeEfC5Gi1DWJl+Edr0wKpu8WvELiLnb0JQFpd9l2YFeuZaqwxq\r
+       J+szpJS6rKg1tHXaz2tFanstUR3KUiuiDMBlyx+4zejy+w3RtKM1RmqFY5r+vp0h1Jp6\r
+       eWyDGULPnfam2Jbwrn8qoLsZyQZk1SVVe/zYAZi+IGPnt/aeVWvcSYXzD3Cw1X8P7eQ/\r
+       p6uc08JBrGIT12K5zI+3FLK19Q8hCBsMMe5P2HN1EyB3xavXJil5IKFbR4q9PkT8Q0yP\r
+       1zNg==\r
+X-Received: by 10.180.91.82 with SMTP id cc18mr8639363wib.7.1377547050235;\r
+       Mon, 26 Aug 2013 12:57:30 -0700 (PDT)\r
+Received: from localhost (93-97-24-31.zone5.bethere.co.uk. [93.97.24.31])\r
+       by mx.google.com with ESMTPSA id li9sm20986335wic.4.1969.12.31.16.00.00\r
+       (version=TLSv1.2 cipher=RC4-SHA bits=128/128);\r
+       Mon, 26 Aug 2013 12:57:29 -0700 (PDT)\r
+From: Mark Walters <markwalters1009@gmail.com>\r
+To: notmuch@notmuchmail.org\r
+Subject: [PATCH 1/2] contrib: pick: remove sync parser\r
+Date: Mon, 26 Aug 2013 20:57:22 +0100\r
+Message-Id: <1377547043-17584-2-git-send-email-markwalters1009@gmail.com>\r
+X-Mailer: git-send-email 1.7.9.1\r
+In-Reply-To: <1377547043-17584-1-git-send-email-markwalters1009@gmail.com>\r
+References: <1377547043-17584-1-git-send-email-markwalters1009@gmail.com>\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 Aug 2013 19:57:37 -0000\r
+\r
+Previously pick had the option of using an async parser like search or\r
+a sync parser like show. The async parser has always been the default\r
+and it seems fine so we can remove the sync one and the corresponding\r
+defcustom.\r
+---\r
+ contrib/notmuch-pick/notmuch-pick.el |   36 ++++++++++-----------------------\r
+ 1 files changed, 11 insertions(+), 25 deletions(-)\r
+\r
+diff --git a/contrib/notmuch-pick/notmuch-pick.el b/contrib/notmuch-pick/notmuch-pick.el\r
+index 37dc161..8c499b0 100644\r
+--- a/contrib/notmuch-pick/notmuch-pick.el\r
++++ b/contrib/notmuch-pick/notmuch-pick.el\r
+@@ -77,11 +77,6 @@\r
+   :type '(alist :key-type (string) :value-type (string))\r
+   :group 'notmuch-pick)\r
\r
+-(defcustom notmuch-pick-asynchronous-parser t\r
+-  "Use the asynchronous parser."\r
+-  :type 'boolean\r
+-  :group 'notmuch-pick)\r
+-\r
+ ;; Faces for messages that match the query.\r
+ (defface notmuch-pick-match-date-face\r
+   '((t :inherit default))\r
+@@ -817,26 +812,17 @@ Complete list of currently available key bindings:\r
+        (message-arg "--entire-thread"))\r
+     (if (equal (car (process-lines notmuch-command "count" search-args)) "0")\r
+       (setq search-args basic-query))\r
+-    (if notmuch-pick-asynchronous-parser\r
+-      (let ((proc (notmuch-start-notmuch\r
+-                   "notmuch-pick" buffer #'notmuch-pick-process-sentinel\r
+-                   "show" "--body=false" "--format=sexp"\r
+-                   message-arg search-args))\r
+-            ;; Use a scratch buffer to accumulate partial output.\r
+-              ;; This buffer will be killed by the sentinel, which\r
+-              ;; should be called no matter how the process dies.\r
+-              (parse-buf (generate-new-buffer " *notmuch pick parse*")))\r
+-          (process-put proc 'parse-buf parse-buf)\r
+-        (set-process-filter proc 'notmuch-pick-process-filter)\r
+-        (set-process-query-on-exit-flag proc nil))\r
+-      (progn\r
+-      (notmuch-pick-insert-forest\r
+-       (notmuch-query-get-threads\r
+-        (list "--body=false" message-arg search-args)))\r
+-      (save-excursion\r
+-        (goto-char (point-max))\r
+-        (insert "End of search results.\n"))))))\r
+-\r
++    (let ((proc (notmuch-start-notmuch\r
++               "notmuch-pick" buffer #'notmuch-pick-process-sentinel\r
++               "show" "--body=false" "--format=sexp"\r
++               message-arg search-args))\r
++        ;; Use a scratch buffer to accumulate partial output.\r
++        ;; This buffer will be killed by the sentinel, which\r
++        ;; should be called no matter how the process dies.\r
++        (parse-buf (generate-new-buffer " *notmuch pick parse*")))\r
++      (process-put proc 'parse-buf parse-buf)\r
++      (set-process-filter proc 'notmuch-pick-process-filter)\r
++      (set-process-query-on-exit-flag proc nil))))\r
\r
+ (defun notmuch-pick (&optional query query-context target buffer-name open-target)\r
+   "Run notmuch pick with the given `query' and display the results.\r
+-- \r
+1.7.9.1\r
+\r