Re: notmuch and "mute" -- useful to anyone?
authorAmadeusz Żołnowski <aidecoe@aidecoe.name>
Tue, 2 Aug 2016 19:28:38 +0000 (20:28 +0100)
committerW. Trevor King <wking@tremily.us>
Sat, 20 Aug 2016 23:22:16 +0000 (16:22 -0700)
62/7ba97c420e58ee5b796df41dae5ca13b5e5339 [new file with mode: 0644]

diff --git a/62/7ba97c420e58ee5b796df41dae5ca13b5e5339 b/62/7ba97c420e58ee5b796df41dae5ca13b5e5339
new file mode 100644 (file)
index 0000000..50a9696
--- /dev/null
@@ -0,0 +1,169 @@
+Return-Path: <aidecoe@aidecoe.name>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+ by arlo.cworth.org (Postfix) with ESMTP id 159E16DE00BD\r
+ for <notmuch@notmuchmail.org>; Tue,  2 Aug 2016 12:29:07 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at cworth.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: 0.473\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=0.473 tagged_above=-999 required=5 tests=[AWL=0.574, \r
+ DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,\r
+ SPF_PASS=-0.001] autolearn=disabled\r
+Received: from arlo.cworth.org ([127.0.0.1])\r
+ by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024)\r
+ with ESMTP id ivbB4MGKJdAJ for <notmuch@notmuchmail.org>;\r
+ Tue,  2 Aug 2016 12:28:58 -0700 (PDT)\r
+Received: from jim.zolnowski.name (jim.zolnowski.name [188.116.54.122])\r
+ by arlo.cworth.org (Postfix) with ESMTPS id 57CA06DE00B8\r
+ for <notmuch@notmuchmail.org>; Tue,  2 Aug 2016 12:28:58 -0700 (PDT)\r
+DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;\r
+ d=aidecoe.name; s=jim; h=Content-Type:MIME-Version:Message-ID:Date:References\r
+ :In-Reply-To:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:\r
+ Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender:\r
+ Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:\r
+ List-Subscribe:List-Post:List-Owner:List-Archive;\r
+ bh=l6HtR8Uikb/eNaqK7OGl8GhxcXq1Bfypo1JFNbMQd5o=; b=sofEQyB9nAJSjj1fI8wjNcdB7K\r
+ Y/A/AdDsNz15KgsZqcbdnZHirWAmqc0ovUru3kUuqumtLJCB5Jb2sbe3Krwr2q1kLJOQK58PK4Y/P\r
+ A8nP8eOSdFNFewFQEK/M0vYi4/b0aM2mcJF1XEr/ZhqdooaSdEH4LR5b9slHUS2gTD6BE1FPEdC2J\r
+ pwNRWkFBkQ+Nheh10o/4O2Ng5+0ZRANBiD3W69ufO3ZkeacA8YUqYWnQeRNqIOJFPAxKP7nBLokio\r
+ H6Mry4TcXk5PV6Ln2Vi8ohZjUwIzc8Vuq2gNQjNTBEuVvPQIyUYwT4u1wOgGfdWj9YKg+b3Cyt68p\r
+ jt4K+4Eg==;\r
+Received: from cpc92302-cmbg19-2-0-cust189.5-4.cable.virginm.net\r
+ ([82.1.208.190] helo=localhost)\r
+ by jim.zolnowski.name with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256)\r
+ (Exim 4.87) (envelope-from <aidecoe@aidecoe.name>)\r
+ id 1bUfMy-0006Bt-2s; Tue, 02 Aug 2016 21:28:53 +0200\r
+From: Amadeusz =?utf-8?B?xbtvxYJub3dza2k=?= <aidecoe@aidecoe.name>\r
+To: Matt Armstrong <marmstrong@google.com>\r
+Cc: notmuch@notmuchmail.org\r
+Subject: Re: notmuch and "mute" -- useful to anyone?\r
+In-Reply-To: <qf5vazjjciq.fsf@marmstrong-linux.kir.corp.google.com>\r
+References: <qf5vazjjciq.fsf@marmstrong-linux.kir.corp.google.com>\r
+User-Agent: Notmuch/0.22.1 (http://notmuchmail.org) Emacs/24.5.1\r
+ (x86_64-pc-linux-gnu)\r
+Date: Tue, 02 Aug 2016 20:28:38 +0100\r
+Message-ID: <87d1lrq8bd.fsf@freja.aidecoe.name>\r
+MIME-Version: 1.0\r
+Content-Type: multipart/signed; boundary="=-=-=";\r
+ micalg=pgp-sha512; protocol="application/pgp-signature"\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.20\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+ <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <https://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: <https://notmuchmail.org/mailman/listinfo/notmuch>,\r
+ <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Tue, 02 Aug 2016 19:29:07 -0000\r
+\r
+--=-=-=\r
+Content-Type: text/plain; charset=utf-8\r
+Content-Transfer-Encoding: quoted-printable\r
+\r
+This seems to be something that https://github.com/teythoon/afew already\r
+does, although it uses tag 'killed' instead. I think that alot e-mail\r
+client uses 'killed' tag as well. Maybe you could consider having that\r
+name instead or make it configurable with 'killed' as default?\r
+\r
+Cheers,\r
+\r
+=2D- Amadeusz =C5=BBo=C5=82nowski\r
+\r
+Matt Armstrong <marmstrong@google.com> writes:\r
+\r
+> Is anyone else interested in Gmail-like "mute" support in notmuch.el?\r
+> If so, I can think about polishing the below off and adding it to\r
+> notmuch.\r
+>\r
+> I've managed to implement Gmail's "mute" in notmuch as follows in my\r
+> notmuch-post-new:\r
+>\r
+> ----------------------------------------------------------------------\r
+> # Unmute all threads with new messages sent to me.\r
+> notmuch search --output=3Dthreads tag:new AND tag:me | \\r
+>   xargs --no-run-if-empty notmuch tag -muted --\r
+>\r
+> # Remove all muted threads from the inbox and mark every message in them\r
+> # muted.  Ideally this would be atomic with the above.\r
+> notmuch search --output=3Dthreads tag:muted | \\r
+>   xargs --no-run-if-empty notmuch tag -inbox +muted --\r
+> ----------------------------------------------------------------------\r
+>\r
+> Then in .emacs:\r
+>\r
+> ----------------------------------------------------------------------\r
+> (defcustom my-notmuch-mute-tags '("+muted" "-inbox")\r
+>   "List of tag changes to apply to a message or a thread when it is muted.\r
+>\r
+> Tags starting with \"+\" (or not starting with either \"+\" or\r
+> \"-\") in the list will be added, and tags starting with \"-\"\r
+> will be removed from the message or thread being archived.\r
+>\r
+> For example, if you wanted to remove an \"inbox\" tag and add an\r
+> \"archived\" tag, you would set:\r
+>     (\"-inbox\" \"+archived\")"\r
+>   :type '(repeat string)\r
+>   :group 'notmuch-search\r
+>   :group 'notmuch-show)\r
+>\r
+> ;; TODO: consider defadvice?\r
+> (defun my-notmuch-search-mute-thread (&optional unarchive beg end)\r
+>   "Mute the currently selected thread or region.\r
+>\r
+> Mute  each message in the currently selected thread by applying the\r
+> tag changes in `my-notmuch-mute-tags' to each (remove the \"inbox\"\r
+> tag by default). If a prefix argument is given, the messages will\r
+> be \"unarchived\" (i.e. the tag changes in `my-notmuch-mute-tags'\r
+> will be reversed).\r
+>\r
+> This function advances the next thread when finished."\r
+>   (interactive (cons current-prefix-arg (notmuch-search-interactive-regio=\r
+n)))\r
+>   (let ((notmuch-archive-tags my-notmuch-mute-tags))\r
+>     (notmuch-search-archive-thread unarchive beg end)))\r
+>\r
+> (defun my-notmuch-show-mute-thread-then-next ()\r
+>   (interactive)\r
+>   "Mute all messages in the current buffer, then show next thread from se=\r
+arch."\r
+>   (let ((notmuch-archive-tags my-notmuch-mute-tags))\r
+>     (notmuch-show-archive-thread-then-next)))\r
+>\r
+> (define-key notmuch-search-mode-map "m" 'my-notmuch-search-mute-thread)\r
+> (define-key notmuch-show-mode-map "m" 'my-notmuch-show-mute-thread-then-n=\r
+ext)\r
+> ----------------------------------------------------------------------\r
+> _______________________________________________\r
+> notmuch mailing list\r
+> notmuch@notmuchmail.org\r
+> https://notmuchmail.org/mailman/listinfo/notmuch\r
+\r
+--=-=-=\r
+Content-Type: application/pgp-signature; name="signature.asc"\r
+\r
+-----BEGIN PGP SIGNATURE-----\r
+Version: GnuPG v2.1\r
+\r
+iQJ8BAEBCgBmBQJXoPRnXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w\r
+ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXRCMzcyRTFENjI5NUM1MzYwQTQwODQyRUZD\r
+QkNDODAyM0Y1OUUxNzA0AAoJEMvMgCP1nhcEX7UP/jSq+b8HBhOdiMA+zui05DO9\r
+5HBiSboLyPZ6i/gHTyFbqC3wyS0zNHozyQl1Ok2yNunxi3QMpMFyYvKcEorPPR4b\r
+VNnsdC7CEo79CReB4EySZAJSH48FrHu8dOh3m6KMRI+Ui4igfUejWySvaZo3hgXE\r
+/01P4SHBcOfFkukQayrXgIryUJwpow6i6Yu4RpkokyoiNWzsmjQ3i6fFXWlKgI0c\r
+OlO9fk88wfoREmQb8e2MNps2oa7fuviruxghvm+Hue4/NYL09jrDmRSbMbrGuVrR\r
+AqkogqV+3xr22zOTV+VkPvsT0+InUBsIdv3lmQtEDKzT7DfATCeXTFGsZQu65IYp\r
+Fx5q1NUTa/hk9xJdvCec/NHj3VO7nhm4lCbbDkXgYs3xomjW7BY2R2uJnWadc0dK\r
+w5zP/1m1pXspCpjcnnGYaRn2uForDMjZELTVkpKAJpMLTekwMkqpgP6KvsKF4cgA\r
+1L9Hh6VcTOpaYVbUUeyTDvWadGxD0RjeTi3Ohfxh2OxTo3LKlJGjYR9Wey/K2Yvc\r
+YSwPX2ksq4v7MTd/RQvansXMCQQIWtuH0fSq+/ps7BVNYpEGr2ScTB38pdpV7hVD\r
+jLHrGdt/TooWuBTj132EUO3TxGFTYACPE4LSssK/vv5x3jupl9CABw0WTtSY5Thp\r
+kbKjj/1zocrx1+RaMWZe\r
+=dSBX\r
+-----END PGP SIGNATURE-----\r
+--=-=-=--\r