1 Return-Path: <jinwoo68@gmail.com>
\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 olra.theworths.org (Postfix) with ESMTP id A45A5431FCB
\r
6 for <notmuch@notmuchmail.org>; Thu, 22 Jan 2015 00:15:58 -0800 (PST)
\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org
\r
11 X-Spam-Status: No, score=2.639 tagged_above=-999 required=5
\r
12 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,
\r
13 DNS_FROM_AHBL_RHSBL=2.438, FREEMAIL_ENVFROM_END_DIGIT=1,
\r
14 FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled
\r
15 Received: from olra.theworths.org ([127.0.0.1])
\r
16 by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)
\r
17 with ESMTP id MHT7N3Nley+V for <notmuch@notmuchmail.org>;
\r
18 Thu, 22 Jan 2015 00:15:55 -0800 (PST)
\r
19 Received: from mail-pd0-f179.google.com (mail-pd0-f179.google.com
\r
20 [209.85.192.179]) (using TLSv1 with cipher RC4-SHA (128/128 bits))
\r
21 (No client certificate requested)
\r
22 by olra.theworths.org (Postfix) with ESMTPS id 099E6431FC9
\r
23 for <notmuch@notmuchmail.org>; Thu, 22 Jan 2015 00:15:55 -0800 (PST)
\r
24 Received: by mail-pd0-f179.google.com with SMTP id v10so263508pde.10
\r
25 for <notmuch@notmuchmail.org>; Thu, 22 Jan 2015 00:15:54 -0800 (PST)
\r
26 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;
\r
27 h=from:to:cc:subject:in-reply-to:references:user-agent:date
\r
28 :message-id:mime-version:content-type;
\r
29 bh=jJoUI1Vyhg7RmXJtDHD8xX3oC9Kn2RIcREYeDnHfwus=;
\r
30 b=JW9+hfnYcQ+K8XcPtsk5ux/FjamtoqYM6svxbxfWdUZyQXDAHAbRdX/BjNs+bWWf4S
\r
31 0a16zn4b2OsgysFeeKkjXnsRijr6QLZTCJPrk+AFs2Naqfyc5eCx4AQ1L2NH9cnoWkM/
\r
32 p3m6JcXmTv8MHy/3btxPDoMApYsqfesK/xav8YLg50NsfDqE+9e0UhooXotHtA9Watgw
\r
33 5X++yUTQYBPCPbu58WXS4DD760LVkGzUoE7CRCS6hZNr/C5vn+xpoo+OBQ9IWvKzmDfT
\r
34 UqMy/Le5Mup1wydbAEhLWkkv5p6Bdpp5JtKrLN2HgDB8E/2MTE56ru67RiwAJrMFAOHC
\r
36 X-Received: by 10.66.124.225 with SMTP id ml1mr202862pab.142.1421914554022;
\r
37 Thu, 22 Jan 2015 00:15:54 -0800 (PST)
\r
38 Received: from localhost ([2601:9:5d00:15b9:9cc3:d58e:e3d6:9990])
\r
39 by mx.google.com with ESMTPSA id nb1sm5149737pdb.85.2015.01.22.00.15.52
\r
40 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
\r
41 Thu, 22 Jan 2015 00:15:52 -0800 (PST)
\r
42 From: Jinwoo Lee <jinwoo68@gmail.com>
\r
43 To: David Bremner <david@tethera.net>, notmuch@notmuchmail.org
\r
44 Subject: Re: [PATCH] emacs: escape % in header line format
\r
45 In-Reply-To: <1421911089-31509-1-git-send-email-david@tethera.net>
\r
46 References: <yq65ppa735xc.fsf@jinwoo-macbookair.roam.corp.google.com>
\r
47 <1421911089-31509-1-git-send-email-david@tethera.net>
\r
48 User-Agent: Notmuch/0.18.1 (http://notmuchmail.org) Emacs/24.4.1
\r
49 (x86_64-apple-darwin13.2.0)
\r
50 Date: Thu, 22 Jan 2015 00:15:50 -0800
\r
51 Message-ID: <yq657fwfcjt5.fsf@jinwoo-macbookair.roam.corp.google.com>
\r
53 Content-Type: text/plain
\r
54 X-BeenThere: notmuch@notmuchmail.org
\r
55 X-Mailman-Version: 2.1.13
\r
57 List-Id: "Use and development of the notmuch mail system."
\r
58 <notmuch.notmuchmail.org>
\r
59 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,
\r
60 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
61 List-Archive: <http://notmuchmail.org/pipermail/notmuch>
\r
62 List-Post: <mailto:notmuch@notmuchmail.org>
\r
63 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
64 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,
\r
65 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
66 X-List-Received-Date: Thu, 22 Jan 2015 08:15:58 -0000
\r
68 Thanks, David. But I don't think it's the correct fix. REPLACE-STRING
\r
69 seems to replace a string in a buffer, not a string given as a param.
\r
70 And it's for interactive use only.
\r
74 On Wed, Jan 21, 2015 at 11:18 PM, David Bremner <david@tethera.net> wrote:
\r
75 > We set header-line-format to the message subject, but if the subject
\r
76 > contains percents, the next character is interpreted as a formatting
\r
77 > control, which is not desired.
\r
80 > Ironically you have to apply this patch to read it's subject properly
\r
81 > ;). There is whitespace change here because the original line was way
\r
84 > emacs/notmuch-show.el | 6 +++++-
\r
85 > 1 file changed, 5 insertions(+), 1 deletion(-)
\r
87 > diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el
\r
88 > index 9f6fe07..4258d43 100644
\r
89 > --- a/emacs/notmuch-show.el
\r
90 > +++ b/emacs/notmuch-show.el
\r
91 > @@ -1198,7 +1198,11 @@ function is used."
\r
92 > (notmuch-show-mapc (lambda () (notmuch-show-set-prop :orig-tags (notmuch-show-get-tags))))
\r
94 > ;; Set the header line to the subject of the first message.
\r
95 > - (setq header-line-format (notmuch-sanitize (notmuch-show-strip-re (notmuch-show-get-subject))))
\r
96 > + (setq header-line-format
\r
97 > + (replace-string "%" "%%"
\r
98 > + (notmuch-sanitize
\r
99 > + (notmuch-show-strip-re
\r
100 > + (notmuch-show-get-subject)))))
\r
102 > (run-hooks 'notmuch-show-hook))))
\r