[PATCH 5/6] emacs: add support for reversing notmuch-search-archive-thread tag changes
authorJani Nikula <jani@nikula.org>
Sun, 2 Sep 2012 19:58:04 +0000 (22:58 +0300)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:49:19 +0000 (09:49 -0800)
6e/96c5100d612b8c759abd41d797c236f29c6dbf [new file with mode: 0644]

diff --git a/6e/96c5100d612b8c759abd41d797c236f29c6dbf b/6e/96c5100d612b8c759abd41d797c236f29c6dbf
new file mode 100644 (file)
index 0000000..303a73b
--- /dev/null
@@ -0,0 +1,106 @@
+Return-Path: <jani@nikula.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 6D620431FC0\r
+       for <notmuch@notmuchmail.org>; Sun,  2 Sep 2012 12:58:26 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References"\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -0.7\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5\r
+       tests=[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 NNvUhySy3U5J for <notmuch@notmuchmail.org>;\r
+       Sun,  2 Sep 2012 12:58:25 -0700 (PDT)\r
+Received: from mail-lpp01m010-f53.google.com (mail-lpp01m010-f53.google.com\r
+       [209.85.215.53]) (using TLSv1 with cipher RC4-SHA (128/128 bits))\r
+       (No client certificate requested)\r
+       by olra.theworths.org (Postfix) with ESMTPS id 659F2431FB6\r
+       for <notmuch@notmuchmail.org>; Sun,  2 Sep 2012 12:58:25 -0700 (PDT)\r
+Received: by mail-lpp01m010-f53.google.com with SMTP id c1so3430631lah.26\r
+       for <notmuch@notmuchmail.org>; Sun, 02 Sep 2012 12:58:25 -0700 (PDT)\r
+X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;\r
+       d=google.com; s=20120113;\r
+       h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references\r
+       :in-reply-to:references:x-gm-message-state;\r
+       bh=fMeP6o5DuzHohZZWfgud7xAXNPMntgwOaeHEqyJeHMs=;\r
+       b=LJAYdnBk8uZiBViDOVzARVw+l/ikO6p0kFGnCmKpLobXD+CXWTpi8ca/FV0nWtcWph\r
+       eD3XoGyqF2tudeADpgu2ZOJIC3Rlx56WixMkMQJTqjXuxfUI0+Dq6OGY5WpcqFxcIqs2\r
+       J+cOPSJKvlNy276N98CV5kwKi3L9tb2w/jHp8Dybs2dJ836W9DTr/SQRVTZPMyns3qAK\r
+       39U3LZwRZaGVBTUQJJpi/hiXb56v+20TnTkdQCIczTZgbQzOLz+R972C+S/pEgV/2wp+\r
+       y8aFkQXkWpZIIcSbzSk/ljH2xGzXWQnm9amRb4rw2w9OJHw0JPXW6JEtThJ9o5bADGko\r
+       y/wA==\r
+Received: by 10.112.99.37 with SMTP id en5mr4766578lbb.25.1346615905047;\r
+       Sun, 02 Sep 2012 12:58:25 -0700 (PDT)\r
+Received: from localhost (dsl-hkibrasgw4-fe51df00-27.dhcp.inet.fi.\r
+       [80.223.81.27])\r
+       by mx.google.com with ESMTPS id lv13sm11363282lab.8.2012.09.02.12.58.23\r
+       (version=SSLv3 cipher=OTHER); Sun, 02 Sep 2012 12:58:24 -0700 (PDT)\r
+From: Jani Nikula <jani@nikula.org>\r
+To: notmuch@notmuchmail.org\r
+Subject: [PATCH 5/6] emacs: add support for reversing\r
+       notmuch-search-archive-thread tag changes\r
+Date: Sun,  2 Sep 2012 22:58:04 +0300\r
+Message-Id:\r
+ <018b1a8f2d1df62e804ce88b65401304832dfbbf.1346614915.git.jani@nikula.org>\r
+X-Mailer: git-send-email 1.7.9.5\r
+In-Reply-To: <cover.1346614915.git.jani@nikula.org>\r
+References: <cover.1346614915.git.jani@nikula.org>\r
+In-Reply-To: <cover.1346614915.git.jani@nikula.org>\r
+References: <cover.1346614915.git.jani@nikula.org>\r
+X-Gm-Message-State:\r
+ ALoCoQn1LtjEiE4c9HOCdvm5t6B2cOJPg45+x+pIVMv4JIppcoFZhVxdGKNZa8HM8u6nP9T2ah9G\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 19:58:26 -0000\r
+\r
+Since archiving a thread can now be a user customized set of tag\r
+changes, make reversing this easier. Allow a prefix argument to\r
+notmuch-search-archive-thread to reverse the archiving, similar to the\r
+unarchiving in notmuch-show-archive-message.\r
+---\r
+ emacs/notmuch.el |    6 +++---\r
+ 1 file changed, 3 insertions(+), 3 deletions(-)\r
+\r
+diff --git a/emacs/notmuch.el b/emacs/notmuch.el\r
+index 64caa3e..a8a85ce 100644\r
+--- a/emacs/notmuch.el\r
++++ b/emacs/notmuch.el\r
+@@ -593,7 +593,7 @@ See `notmuch-tag' for information on the format of TAG-CHANGES."\r
+   (interactive)\r
+   (notmuch-search-tag "-"))\r
+ \r
+-(defun notmuch-search-archive-thread ()\r
++(defun notmuch-search-archive-thread (&optional unarchive)\r
+   "Archive the currently selected thread.\r
+ \r
+ Archive each message in the currently selected thread by applying\r
+@@ -603,10 +603,10 @@ messages will be \"unarchived\" (i.e. the tag changes in\r
+ `notmuch-archive-tags' will be reversed).\r
+ \r
+ This function advances the next thread when finished."\r
+-  (interactive)\r
++  (interactive "P")\r
+   (when notmuch-archive-tags\r
+     (notmuch-search-tag\r
+-     (notmuch-tag-change-list notmuch-archive-tags)))\r
++     (notmuch-tag-change-list notmuch-archive-tags unarchive)))\r
+   (notmuch-search-next-thread))\r
+ \r
+ (defun notmuch-search-update-result (result &optional pos)\r
+-- \r
+1.7.9.5\r
+\r