From: Matt Armstrong Date: Wed, 3 Aug 2016 17:33:01 +0000 (+1700) Subject: Re: notmuch and "mute" -- useful to anyone? X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=d1b8c154b0545191b6010496bbba9a92989168df;p=notmuch-archives.git Re: notmuch and "mute" -- useful to anyone? --- diff --git a/68/7718caa124ef4e83b75a9a8a833d7e3671db5f b/68/7718caa124ef4e83b75a9a8a833d7e3671db5f new file mode 100644 index 000000000..3ee561e33 --- /dev/null +++ b/68/7718caa124ef4e83b75a9a8a833d7e3671db5f @@ -0,0 +1,126 @@ +Return-Path: +X-Original-To: notmuch@notmuchmail.org +Delivered-To: notmuch@notmuchmail.org +Received: from localhost (localhost [127.0.0.1]) + by arlo.cworth.org (Postfix) with ESMTP id 0B5B86DE0173 + for ; Wed, 3 Aug 2016 10:33:13 -0700 (PDT) +X-Virus-Scanned: Debian amavisd-new at cworth.org +X-Spam-Flag: NO +X-Spam-Score: -0.911 +X-Spam-Level: +X-Spam-Status: No, score=-0.911 tagged_above=-999 required=5 tests=[AWL=0.111, + DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, + RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H2=-0.211, SPF_PASS=-0.001, + T_RP_MATCHES_RCVD=-0.01] autolearn=disabled +Received: from arlo.cworth.org ([127.0.0.1]) + by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024) + with ESMTP id jVG0EWLfNSYM for ; + Wed, 3 Aug 2016 10:33:05 -0700 (PDT) +Received: from mail-pf0-f170.google.com (mail-pf0-f170.google.com + [209.85.192.170]) + by arlo.cworth.org (Postfix) with ESMTPS id F15FC6DE0005 + for ; Wed, 3 Aug 2016 10:33:04 -0700 (PDT) +Received: by mail-pf0-f170.google.com with SMTP id y134so79450072pfg.0 + for ; Wed, 03 Aug 2016 10:33:04 -0700 (PDT) +DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; + s=20120113; + h=from:to:subject:in-reply-to:references:user-agent:date:message-id + :mime-version; bh=yh/CEp5Ku8L0yrypSjbljIUdejWE4ACzFOWfU6nqXE0=; + b=OHGL4vdBM5sK27xAPSfWezBKtmRSLLSQxA2qycS4ssterFfPZ0t8cbBJMr9zbfTMG/ + eJZfmTdgAFi676h32c2LhoJp0BRBIgyiqbDRA8E1BzYL34gn51jyUyCpRqKA9YJ8pon3 + n26V/dA7q8Kg8fjOsVGqCA+c8hbTv+4z+NQHO6OmBebB6KPp+henIRLa7v+Qed6M2Fo4 + CID5805X4vpuMRzzGLVrxmYXPF/Itzpmk0gjb5G+8NzlC0P2oqbdVe414xaekx7GS1ip + Nn1dYl5FGAPRArhqtk8XQxF5yxD9r3b1K3rBrSrwmyK0onXfMAw6N3a/XfhppwDvPSYU +2lg== +X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; + d=1e100.net; s=20130820; + h=x-gm-message-state:from:to:subject:in-reply-to:references + :user-agent:date:message-id:mime-version; + bh=yh/CEp5Ku8L0yrypSjbljIUdejWE4ACzFOWfU6nqXE0=; + b=huNZKMwkO/vPQ++vIMF/HtqGjdWrf+Gz4oS5/ZX6yYxEQIhPCDqb7J76N4l+mv2gDL + sISFk8NMEFJq4jUOJhCXIjHhg8cQBt36uI/8/M+quUN/oqdpoD60tw3XZft0qk0xcDY3 + 5yF/B2s/2ksGB7rV4B9C1HCP9E/OlBmNFQ/GyDRro/QD94pE5aBYFSbeAs0d6sqRI6Wj + ysK8Hq1gD13VHDBIvIJA8dKjr5SQ85VyfFPp7wkfeK95/Y33Oh+1RABM5mvt5jtqI9bO + bZC3HzH17+zyRrGVGOTNoU1Oc9dfpKT+9Rx2IBIG+tBwuXWZSD2ZxQat1hNzUtCNqN1o + zCaA== +X-Gm-Message-State: + AEkoousFI4ye+l7XDJDTM9kBIxFH8gwyFXVX0CLSDeJc8WwchMahZqfs0EAcZ63t7h0nOlje +X-Received: by 10.98.147.156 with SMTP id r28mr96546918pfk.154.1470245583709; + Wed, 03 Aug 2016 10:33:03 -0700 (PDT) +Received: from marmstrong-linux.kir.corp.google.com + ([2620:0:1008:11:c0a0:ba91:a737:fbef]) + by smtp.gmail.com with ESMTPSA id h125sm14102391pfg.54.2016.08.03.10.33.02 + (version=TLS1_2 cipher=AES128-SHA bits=128/128); + Wed, 03 Aug 2016 10:33:02 -0700 (PDT) +From: Matt Armstrong +To: David Bremner , notmuch@notmuchmail.org +Subject: Re: notmuch and "mute" -- useful to anyone? +In-Reply-To: <87invivm2y.fsf@maritornes.cs.unb.ca> +References: + <87invivm2y.fsf@maritornes.cs.unb.ca> +User-Agent: Notmuch/0.21 (https://notmuchmail.org) Emacs/24.3.1 + (x86_64-pc-linux-gnu) +Date: Wed, 03 Aug 2016 10:33:01 -0700 +Message-ID: +MIME-Version: 1.0 +Content-Type: text/plain +X-BeenThere: notmuch@notmuchmail.org +X-Mailman-Version: 2.1.20 +Precedence: list +List-Id: "Use and development of the notmuch mail system." + +List-Unsubscribe: , + +List-Archive: +List-Post: +List-Help: +List-Subscribe: , + +X-List-Received-Date: Wed, 03 Aug 2016 17:33:13 -0000 + +David Bremner writes: + +> Matt Armstrong writes: +> +>> Is anyone else interested in Gmail-like "mute" support in notmuch.el? +>> If so, I can think about polishing the below off and adding it to +>> notmuch. +>> +>> I've managed to implement Gmail's "mute" in notmuch as follows in my +>> notmuch-post-new: +>> +>> ---------------------------------------------------------------------- +>> # Unmute all threads with new messages sent to me. +>> notmuch search --output=threads tag:new AND tag:me | \ +>> xargs --no-run-if-empty notmuch tag -muted -- +>> +>> # Remove all muted threads from the inbox and mark every message in them +>> # muted. Ideally this would be atomic with the above. +>> notmuch search --output=threads tag:muted | \ +>> xargs --no-run-if-empty notmuch tag -inbox +muted -- +>> ---------------------------------------------------------------------- +> +> See also the example of https://notmuchmail.org/excluding/ +> +> This kind of thing is what message exclusion is invented for. +> +> I guess you have to adjust to get precisely the semantics you want where +> messages specifically to you are not muted. + +"mute" is a bit odd. It is essentially "new messages in this thread +skip the inbox". It is a property of a thread, not a message. + +It has little to do with excluding messages from arbitrary searches. In +particular, muted threads should show up in normal free text searches. +I don't think message exclusion is the right mechanism. + +The spec is: when a message arrives, + if it is "to me" unmute any thread it is part of + otherwise if it is in a muted thread, avoid tagging it "inbox" + +This is a little bit hard to deal with in a the notmuch model, which +deals more naturally with mechanisms that tag individual messages and +handles threading as a post-search message gathering step (as far as I +can tell). + +I'm not claiming that what I've got is optimal -- it feels like a hack +to me, but is the best I came up with.