1 Return-Path: <tomi.ollila@iki.fi>
\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 2FC6C431FBC
\r
6 for <notmuch@notmuchmail.org>; Wed, 28 Aug 2013 13:47:06 -0700 (PDT)
\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org
\r
11 X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none]
\r
13 Received: from olra.theworths.org ([127.0.0.1])
\r
14 by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)
\r
15 with ESMTP id YchIN6f5PUQC for <notmuch@notmuchmail.org>;
\r
16 Wed, 28 Aug 2013 13:46:58 -0700 (PDT)
\r
17 Received: from guru.guru-group.fi (guru.guru-group.fi [46.183.73.34])
\r
18 by olra.theworths.org (Postfix) with ESMTP id 8D9FF431FAE
\r
19 for <notmuch@notmuchmail.org>; Wed, 28 Aug 2013 13:46:58 -0700 (PDT)
\r
20 Received: from guru.guru-group.fi (localhost [IPv6:::1])
\r
21 by guru.guru-group.fi (Postfix) with ESMTP id BC303100030;
\r
22 Wed, 28 Aug 2013 23:46:48 +0300 (EEST)
\r
23 From: Tomi Ollila <tomi.ollila@iki.fi>
\r
24 To: Jani Nikula <jani@nikula.org>,
\r
25 Geoffrey Ferrari <geoffrey.ferrari@oriel.oxon.org>, notmuch@notmuchmail.org
\r
26 Subject: Re: [PATCH] emacs: bugfix notmuch-mua-reply when signature is present
\r
27 In-Reply-To: <87sixtsj1y.fsf@nikula.org>
\r
29 <1375961732-14327-1-git-send-email-geoffrey.ferrari@oriel.oxon.org>
\r
30 <m2sixtyb5k.fsf@guru.guru-group.fi> <m2ob8hy7da.fsf@guru.guru-group.fi>
\r
31 <87sixtsj1y.fsf@nikula.org>
\r
32 User-Agent: Notmuch/0.16+42~g938dae6 (http://notmuchmail.org) Emacs/24.3.1
\r
33 (x86_64-unknown-linux-gnu)
\r
34 X-Face: HhBM'cA~<r"^Xv\KRN0P{vn'Y"Kd;zg_y3S[4)KSN~s?O\"QPoL
\r
35 $[Xv_BD:i/F$WiEWax}R(MPS`^UaptOGD`*/=@\1lKoVa9tnrg0TW?"r7aRtgk[F
\r
36 !)g;OY^,BjTbr)Np:%c_o'jj,Z
\r
37 Date: Wed, 28 Aug 2013 23:46:48 +0300
\r
38 Message-ID: <m2y57lfsqv.fsf@guru.guru-group.fi>
\r
40 Content-Type: text/plain
\r
41 X-BeenThere: notmuch@notmuchmail.org
\r
42 X-Mailman-Version: 2.1.13
\r
44 List-Id: "Use and development of the notmuch mail system."
\r
45 <notmuch.notmuchmail.org>
\r
46 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,
\r
47 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
48 List-Archive: <http://notmuchmail.org/pipermail/notmuch>
\r
49 List-Post: <mailto:notmuch@notmuchmail.org>
\r
50 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
51 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,
\r
52 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
53 X-List-Received-Date: Wed, 28 Aug 2013 20:47:06 -0000
\r
55 On Wed, Aug 28 2013, Jani Nikula <jani@nikula.org> wrote:
\r
57 > On Wed, 28 Aug 2013, Tomi Ollila <tomi.ollila@iki.fi> wrote:
\r
58 >> On Wed, Aug 28 2013, Tomi Ollila <tomi.ollila@iki.fi> wrote:
\r
60 >>> On Thu, Aug 08 2013, Geoffrey Ferrari <geoffrey.ferrari@oriel.oxon.org> wrote:
\r
62 >>>> From: "Geoffrey H. Ferrari" <geoffrey.ferrari@oriel.oxon.org>
\r
64 >>>> When composing a reply, notmuch-mua-reply tries to be smart and cite
\r
65 >>>> the original message by inserting it before the user signature, if
\r
66 >>>> one is present. However, the existing method of backward searching
\r
67 >>>> from the end of the buffer to find the signature separator and then
\r
68 >>>> moving one line up results in the original message being cited in
\r
69 >>>> the message headers. That's because at this point the message looks
\r
70 >>>> like this (with | representing point after searching for the
\r
71 >>>> signature separator):
\r
76 >>>> --text follows this line--
\r
78 >>>> My fancy signature
\r
80 >>> Now that I tested, (with ~/.signature), composing new mail starts with
\r
82 >>> --8<---8<---8<---8<---8<---8<---8<---8<---8<-
\r
83 >>> From: Tomi Ollila <tomi.ollila@iki.fi>
\r
86 >>> Fcc: /home/too/mail/mails/sent
\r
87 >>> --text follows this line--
\r
91 >>> --8<---8<---8<---8<---8<---8<---8<---8<---8<-
\r
93 >>> Notice the empty line between '--text follows this line--' and '--'
\r
95 >>> In your example, the signature block is -- for some reason --
\r
96 >>> inserted without the empty line.
\r
98 >>>> With this patch, a newline is opened instead, so that the orignal
\r
99 >>>> message is cited above the signature but still in the message text.
\r
103 >>>> (goto-char (point-max))
\r
104 >>>> (if (re-search-backward message-signature-separator nil t)
\r
105 >>>>- (forward-line -1)
\r
107 >>>> (goto-char (point-max)))
\r
109 >> If the case is like I think, it should have used (open-line 1) instead.
\r
111 >> Anyway, what about:
\r
113 > Hi Tomi, what about [1] instead? KISS and all that.
\r
115 Indeed, I just looked that. Looks Good. Will test tomorrow...
\r
123 PS: my test signature intentionally left there ;)
\r
126 > [1] id:cover.1377718199.git.jani@nikula.org
\r
130 >> (goto-char (point-max))
\r
131 >> (when (re-search-backward message-signature-separator nil t)
\r
132 >> (forward-line -1)
\r
137 >> The else clause with (goto-char (point-max)) is unnecessary as
\r
138 >> with the third argument NOERROR being t point is moved if
\r
139 >> re-search-backward doesn't find match.
\r
146 >> _______________________________________________
\r
147 >> notmuch mailing list
\r
148 >> notmuch@notmuchmail.org
\r
149 >> http://notmuchmail.org/mailman/listinfo/notmuch
\r
155 > _______________________________________________
\r
156 > notmuch mailing list
\r
157 > notmuch@notmuchmail.org
\r
158 > http://notmuchmail.org/mailman/listinfo/notmuch
\r