1 Return-Path: <dme@dme.org>
\r
2 X-Original-To: notmuch@notmuchmail.org
\r
3 Delivered-To: notmuch@notmuchmail.org
\r
4 Received: from localhost (localhost [127.0.0.1])
\r
5 by arlo.cworth.org (Postfix) with ESMTP id 33F9D6DE1607
\r
6 for <notmuch@notmuchmail.org>; Fri, 29 Jan 2016 09:27:10 -0800 (PST)
\r
7 X-Virus-Scanned: Debian amavisd-new at cworth.org
\r
11 X-Spam-Status: No, score=0.359 tagged_above=-999 required=5 tests=[AWL=0.426,
\r
12 DKIM_SIGNED=0.1, DKIM_VALID=-0.1, RCVD_IN_DNSWL_LOW=-0.7,
\r
13 RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_NEUTRAL=0.652,
\r
14 UNPARSEABLE_RELAY=0.001] autolearn=disabled
\r
15 Received: from arlo.cworth.org ([127.0.0.1])
\r
16 by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024)
\r
17 with ESMTP id eUIOqN2n5Rc3 for <notmuch@notmuchmail.org>;
\r
18 Fri, 29 Jan 2016 09:27:06 -0800 (PST)
\r
19 Received: from mail-wm0-f67.google.com (mail-wm0-f67.google.com
\r
20 [74.125.82.67]) by arlo.cworth.org (Postfix) with ESMTPS id 9ED416DE009A for
\r
21 <notmuch@notmuchmail.org>; Fri, 29 Jan 2016 09:27:06 -0800 (PST)
\r
22 Received: by mail-wm0-f67.google.com with SMTP id p63so11099933wmp.1
\r
23 for <notmuch@notmuchmail.org>; Fri, 29 Jan 2016 09:27:06 -0800 (PST)
\r
24 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
\r
25 d=dme-org.20150623.gappssmtp.com; s=20150623;
\r
26 h=from:to:subject:date:message-id;
\r
27 bh=r/5v2XvnH7kdeX0im8ajlcPe0YMpi1oeVR30jxL20ws=;
\r
28 b=wUrQYac6ba9gRJa3i771FMb+iEPpS2Z6vbIC8RRqD0JPf3v/6tQ3XmjRVAD+ZadlgP
\r
29 absxaLlW4ll+4IVZeJG6gyhhDKbQYOCW+ro8GVk6N2fWEfcEW4293rTSnn/AOuXC3EXF
\r
30 qalRnc75pv2UWVkVPF8irHBeKLfVBF8ojgOYpmw1zaTdW7RrEqbgLEEzaDXJRqvSNSY+
\r
31 vRsuet7onE6itbOaFrzkuVygyTqXcZM62Ib0NhSslUavXe7adU+qLvNtvW0bg6BxnNLt
\r
32 DV1aAvvyeVOSW8kTvg8klyR3xbuqiDC3K1VzIvMuphO6g/vLASZ9nuMuXrlyCYHO7pLI
\r
34 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
\r
35 d=1e100.net; s=20130820;
\r
36 h=x-gm-message-state:from:to:subject:date:message-id;
\r
37 bh=r/5v2XvnH7kdeX0im8ajlcPe0YMpi1oeVR30jxL20ws=;
\r
38 b=VwcmcPM+Q2iepN3Cnh4utXzsw7R6TDRTaF43wyrYUxPKaQ/lpOr3eYnQ9M3NNGmNyE
\r
39 17HVsNvv9nw2qjyOfJZpsG17Z9iTLgnoDU4Z6igVyiL0uAPDngonGzZ5ptwBMdj7IMiP
\r
40 CCD543VcfLdvEmARVsJZBl8WBYqMRNMt0dv+9DzRWGVGqmkzJPwlf1xC6n+L3kWCVsJ+
\r
41 48IypulXNigQkl7g9SNjyilSaSA6Ynwj+u/Zgakw3Sflnd1jJegRCdPPqupA0oQ1IoRR
\r
42 uubwAy2h3wLoBF8XZ7gJLjq8BtgdBOZjxhSRNLi9iBmlUnLzYNWvxFbvR5ksJaMJC+0g
\r
45 AG10YOT60eMlndi9nyam/5Bsgknx0mr+YdbvXwJm13e3D+vPmHRPDQnisje0kDlWHvt7qg==
\r
46 X-Received: by 10.28.175.147 with SMTP id y141mr9779642wme.64.1454088424630;
\r
47 Fri, 29 Jan 2016 09:27:04 -0800 (PST)
\r
48 Received: from disaster-area.hh.sledj.net
\r
49 ([2a01:348:1a2:1:ea39:35ff:fe2c:a227])
\r
50 by smtp.gmail.com with ESMTPSA id e9sm16533897wja.25.2016.01.29.09.27.02
\r
51 for <notmuch@notmuchmail.org>
\r
52 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
\r
53 Fri, 29 Jan 2016 09:27:03 -0800 (PST)
\r
54 Received: from localhost (disaster-area.hh.sledj.net [local])
\r
55 by disaster-area.hh.sledj.net (OpenSMTPD) with ESMTPA id 7e6677fb
\r
56 for <notmuch@notmuchmail.org>; Fri, 29 Jan 2016 17:27:02 +0000 (UTC)
\r
57 From: David Edmondson <dme@dme.org>
\r
58 To: notmuch@notmuchmail.org
\r
59 Subject: [PATCH v2] Allow content preference based on message content.
\r
60 Date: Fri, 29 Jan 2016 17:27:00 +0000
\r
61 Message-Id: <1454088421-6081-1-git-send-email-dme@dme.org>
\r
62 X-Mailer: git-send-email 2.6.3
\r
63 X-BeenThere: notmuch@notmuchmail.org
\r
64 X-Mailman-Version: 2.1.20
\r
66 List-Id: "Use and development of the notmuch mail system."
\r
67 <notmuch.notmuchmail.org>
\r
68 List-Unsubscribe: <https://notmuchmail.org/mailman/options/notmuch>,
\r
69 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
70 List-Archive: <http://notmuchmail.org/pipermail/notmuch/>
\r
71 List-Post: <mailto:notmuch@notmuchmail.org>
\r
72 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
73 List-Subscribe: <https://notmuchmail.org/mailman/listinfo/notmuch>,
\r
74 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
75 X-List-Received-Date: Fri, 29 Jan 2016 17:27:10 -0000
\r
78 Allow content preference based on message content.
\r
80 An example configuration might be:
\r
82 (defun dme:determine-discouraged (msg)
\r
83 (let* ((headers (plist-get msg :headers))
\r
84 (from (plist-get headers :From)))
\r
86 ((string-match "9195404@capita-intouch.co.uk" from)
\r
89 '("text/html" "multipart/related")))))
\r
91 (setq notmuch-multipart/alternative-discouraged
\r
92 'dme:determine-discouraged)
\r
94 This would discourage text/html and multipart/related generally, but
\r
95 discourage text/plain should the message be sent from
\r
96 9195404@capita-intouch.co.uk.
\r
99 - Remove the simple evaluation variant based on feedback.
\r
102 David Edmondson (1):
\r
103 emacs: Allow part preferences to depend on message content.
\r
105 emacs/notmuch-lib.el | 20 ++++++++++++++++----
\r
106 emacs/notmuch-mua.el | 2 +-
\r
107 emacs/notmuch-show.el | 2 +-
\r
108 3 files changed, 18 insertions(+), 6 deletions(-)
\r