[Patch v3 1/3] contrib: pick: remove unneeded variable notmuch-pick-buffer-name
authorMark Walters <markwalters1009@gmail.com>
Mon, 2 Sep 2013 20:15:12 +0000 (21:15 +0100)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:56:50 +0000 (09:56 -0800)
3a/114b53b0b85c622c18e0cb5b6bad74cb744b8e [new file with mode: 0644]

diff --git a/3a/114b53b0b85c622c18e0cb5b6bad74cb744b8e b/3a/114b53b0b85c622c18e0cb5b6bad74cb744b8e
new file mode 100644 (file)
index 0000000..3237d6b
--- /dev/null
@@ -0,0 +1,149 @@
+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 3E78D431FD6\r
+       for <notmuch@notmuchmail.org>; Mon,  2 Sep 2013 13:15:28 -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 Lyn2H7yN-CVx for <notmuch@notmuchmail.org>;\r
+       Mon,  2 Sep 2013 13:15:22 -0700 (PDT)\r
+Received: from mail-we0-f169.google.com (mail-we0-f169.google.com\r
+       [74.125.82.169]) (using TLSv1 with cipher RC4-SHA (128/128 bits))\r
+       (No client certificate requested)\r
+       by olra.theworths.org (Postfix) with ESMTPS id D26B9431FCB\r
+       for <notmuch@notmuchmail.org>; Mon,  2 Sep 2013 13:15:21 -0700 (PDT)\r
+Received: by mail-we0-f169.google.com with SMTP id t60so830676wes.28\r
+       for <notmuch@notmuchmail.org>; Mon, 02 Sep 2013 13:15:20 -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=vqrz/yQXi0ullr1bYRNIrYdLiZbLXx9fSdItbfvIDWc=;\r
+       b=DMh3iXFtzDXkj+dMTsPGY5bsFBaMzGCNTwjfGdVnbXL0DywFCilLLPUohNWObv0WTO\r
+       ciI4tUoZTXkgTNWK/n1XhpHsXJsTJo0scXbZNMxq6/CptuU7peEkO9eMeDpnluglj76c\r
+       wXyyBU+VWIrcvzNl+lH7Zw9kbT13yvKttTckxtBkfk6e8QuAjbNskXGHGDz72IHS6/dI\r
+       UrIZOSksU7ynC7Qfi2rBoq/wkW0qCvo+NCYKPHuX669fJUWJXaHh6c+dMkR7NKX8MJJ1\r
+       U3b7PADasdyZwYnzgUx3ZGxPVx9eFHkcT3XeDHtVbv4bT7KKVKFmhlPlxKckSnj+s9ok\r
+       45gA==\r
+X-Received: by 10.180.206.9 with SMTP id lk9mr15132381wic.26.1378152920771;\r
+       Mon, 02 Sep 2013 13:15:20 -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\r
+       dr11sm20835614wid.3.1969.12.31.16.00.00\r
+       (version=TLSv1.2 cipher=RC4-SHA bits=128/128);\r
+       Mon, 02 Sep 2013 13:15:20 -0700 (PDT)\r
+From: Mark Walters <markwalters1009@gmail.com>\r
+To: notmuch@notmuchmail.org\r
+Subject: [Patch v3 1/3] contrib: pick: remove unneeded variable\r
+       notmuch-pick-buffer-name\r
+Date: Mon,  2 Sep 2013 21:15:12 +0100\r
+Message-Id: <1378152914-18930-2-git-send-email-markwalters1009@gmail.com>\r
+X-Mailer: git-send-email 1.7.9.1\r
+In-Reply-To: <1378152914-18930-1-git-send-email-markwalters1009@gmail.com>\r
+References: <1378152914-18930-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, 02 Sep 2013 20:15:28 -0000\r
+\r
+This variable is essentially unused: it was only used for making sure\r
+it itself got reset after a refresh of the buffer.\r
+\r
+It did this by passing an unnecessary argument to notmuch-pick-worker\r
+so remove that too.\r
+---\r
+ contrib/notmuch-pick/notmuch-pick.el |   25 +++++++++----------------\r
+ 1 files changed, 9 insertions(+), 16 deletions(-)\r
+\r
+diff --git a/contrib/notmuch-pick/notmuch-pick.el b/contrib/notmuch-pick/notmuch-pick.el\r
+index f7caaa8..32bd6b5 100644\r
+--- a/contrib/notmuch-pick/notmuch-pick.el\r
++++ b/contrib/notmuch-pick/notmuch-pick.el\r
+@@ -161,10 +161,6 @@\r
+   "A buffer local copy of argument open-target to the function notmuch-pick")\r
+ (make-variable-buffer-local 'notmuch-pick-open-target)\r
\r
+-(defvar notmuch-pick-buffer-name nil\r
+-  "A buffer local copy of argument buffer-name to the function notmuch-pick")\r
+-(make-variable-buffer-local 'notmuch-pick-buffer-name)\r
+-\r
+ (defvar notmuch-pick-message-window nil\r
+   "The window of the message pane.\r
\r
+@@ -590,13 +586,11 @@ message will be \"unarchived\", i.e. the tag changes in\r
+   (let ((inhibit-read-only t)\r
+       (basic-query notmuch-pick-basic-query)\r
+       (query-context notmuch-pick-query-context)\r
+-      (target (notmuch-pick-get-message-id))\r
+-      (buffer-name notmuch-pick-buffer-name))\r
++      (target (notmuch-pick-get-message-id)))\r
+     (erase-buffer)\r
+     (notmuch-pick-worker basic-query\r
+                        query-context\r
+-                       target\r
+-                       (get-buffer buffer-name))))\r
++                       target)))\r
\r
+ (defun notmuch-pick-thread-top ()\r
+   (when (notmuch-pick-get-message-properties)\r
+@@ -859,12 +853,11 @@ Complete list of currently available key bindings:\r
+       (notmuch-sexp-parse-partial-list 'notmuch-pick-insert-forest-thread\r
+                                        results-buf)))))\r
\r
+-(defun notmuch-pick-worker (basic-query &optional query-context target buffer open-target)\r
++(defun notmuch-pick-worker (basic-query &optional query-context target open-target)\r
+   (interactive)\r
+   (notmuch-pick-mode)\r
+   (setq notmuch-pick-basic-query basic-query)\r
+   (setq notmuch-pick-query-context query-context)\r
+-  (setq notmuch-pick-buffer-name (buffer-name buffer))\r
+   (setq notmuch-pick-target-msg target)\r
+   (setq notmuch-pick-open-target open-target)\r
\r
+@@ -877,7 +870,7 @@ Complete list of currently available key bindings:\r
+     (if (equal (car (process-lines notmuch-command "count" search-args)) "0")\r
+       (setq search-args basic-query))\r
+     (let ((proc (notmuch-start-notmuch\r
+-               "notmuch-pick" buffer #'notmuch-pick-process-sentinel\r
++               "notmuch-pick" (current-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
+@@ -910,13 +903,13 @@ The arguments are:\r
+                                       (concat "*notmuch-pick-" query "*")))))\r
+       (inhibit-read-only t))\r
\r
+-    (switch-to-buffer buffer)\r
+-    ;; Don't track undo information for this buffer\r
+-    (set 'buffer-undo-list t)\r
++    (switch-to-buffer buffer))\r
++  ;; Don't track undo information for this buffer\r
++  (set 'buffer-undo-list t)\r
\r
+-    (notmuch-pick-worker query query-context target buffer open-target)\r
++  (notmuch-pick-worker query query-context target open-target)\r
\r
+-    (setq truncate-lines t)))\r
++  (setq truncate-lines t))\r
\r
\r
+ ;; Set up key bindings from the rest of notmuch.\r
+-- \r
+1.7.9.1\r
+\r