Re: [PATCH 0/4] Allow specifying alternate names for addresses in other_email
[notmuch-archives.git] / ef / 2782cc0d7231ffc4fd75406903f712d0473799
1 Return-Path: <sojkam1@fel.cvut.cz>\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 498696DE179D\r
6  for <notmuch@notmuchmail.org>; Tue, 29 Dec 2015 13:56:11 -0800 (PST)\r
7 X-Virus-Scanned: Debian amavisd-new at cworth.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: -1.532\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=-1.532 tagged_above=-999 required=5 tests=[AWL=1.318,\r
12   RCVD_IN_DNSWL_MED=-2.3, RP_MATCHES_RCVD=-0.55] autolearn=disabled\r
13 Received: from arlo.cworth.org ([127.0.0.1])\r
14  by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024)\r
15  with ESMTP id wLUx9rrWuFxX for <notmuch@notmuchmail.org>;\r
16  Tue, 29 Dec 2015 13:56:09 -0800 (PST)\r
17 Received: from max.feld.cvut.cz (max.feld.cvut.cz [147.32.192.36])\r
18  by arlo.cworth.org (Postfix) with ESMTP id 8798F6DE1767\r
19  for <notmuch@notmuchmail.org>; Tue, 29 Dec 2015 13:56:09 -0800 (PST)\r
20 Received: from localhost (unknown [192.168.200.7])\r
21  by max.feld.cvut.cz (Postfix) with ESMTP id CE60819F47EB\r
22  for <notmuch@notmuchmail.org>; Tue, 29 Dec 2015 22:56:08 +0100 (CET)\r
23 X-Virus-Scanned: IMAP STYX AMAVIS\r
24 Received: from max.feld.cvut.cz ([192.168.200.1])\r
25  by localhost (styx.feld.cvut.cz [192.168.200.7]) (amavisd-new, port 10044)\r
26  with ESMTP id ksJjpyAwNyd3 for <notmuch@notmuchmail.org>;\r
27  Tue, 29 Dec 2015 22:56:07 +0100 (CET)\r
28 Received: from imap.feld.cvut.cz (imap.feld.cvut.cz [147.32.192.34])\r
29  by max.feld.cvut.cz (Postfix) with ESMTP id 4B37A19F463E\r
30  for <notmuch@notmuchmail.org>; Tue, 29 Dec 2015 22:56:07 +0100 (CET)\r
31 Received: from wsh by steelpick.2x.cz with local (Exim 4.86)\r
32  (envelope-from <sojkam1@fel.cvut.cz>)\r
33  id 1aE2FS-0003zX-UJ; Tue, 29 Dec 2015 22:56:06 +0100\r
34 From: Michal Sojka <sojkam1@fel.cvut.cz>\r
35 To: notmuch@notmuchmail.org\r
36 Subject: [PATCH] doc/reply: Clarify how reply-to header is handled\r
37 Date: Tue, 29 Dec 2015 22:55:40 +0100\r
38 Message-Id: <1451426140-15303-1-git-send-email-sojkam1@fel.cvut.cz>\r
39 X-Mailer: git-send-email 2.6.4\r
40 In-Reply-To: <8760zgdioq.fsf@steelpick.2x.cz>\r
41 References: <8760zgdioq.fsf@steelpick.2x.cz>\r
42 X-BeenThere: notmuch@notmuchmail.org\r
43 X-Mailman-Version: 2.1.20\r
44 Precedence: list\r
45 List-Id: "Use and development of the notmuch mail system."\r
46  <notmuch.notmuchmail.org>\r
47 List-Unsubscribe: <https://notmuchmail.org/mailman/options/notmuch>,\r
48  <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
49 List-Archive: <http://notmuchmail.org/pipermail/notmuch/>\r
50 List-Post: <mailto:notmuch@notmuchmail.org>\r
51 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
52 List-Subscribe: <https://notmuchmail.org/mailman/listinfo/notmuch>,\r
53  <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
54 X-List-Received-Date: Tue, 29 Dec 2015 21:56:11 -0000\r
55 \r
56 Current documentation and comments in the code do not correspond to\r
57 the actual code and tests in the test suite ("Un-munging Reply-To" in\r
58 T230-reply-to-sender.sh). Fix it.\r
59 ---\r
60  doc/man1/notmuch-reply.rst | 6 ++++--\r
61  notmuch-reply.c            | 2 +-\r
62  2 files changed, 5 insertions(+), 3 deletions(-)\r
63 \r
64 diff --git a/doc/man1/notmuch-reply.rst b/doc/man1/notmuch-reply.rst\r
65 index cfbd4ea..d73f8f1 100644\r
66 --- a/doc/man1/notmuch-reply.rst\r
67 +++ b/doc/man1/notmuch-reply.rst\r
68 @@ -13,8 +13,10 @@ DESCRIPTION\r
69  Constructs a reply template for a set of messages.\r
70  \r
71  To make replying to email easier, **notmuch reply** takes an existing\r
72 -set of messages and constructs a suitable mail template. The Reply-to:\r
73 -header (if any, otherwise From:) is used for the To: address. Unless\r
74 +set of messages and constructs a suitable mail template. Its To:\r
75 +address is set according to the original email in this way: if the\r
76 +Reply-to: header is present and different from any To:/Cc: address it\r
77 +is used, otherwise From: header is used. Unless\r
78  ``--reply-to=sender`` is specified, values from the To: and Cc: headers\r
79  are copied, but not including any of the current user's email addresses\r
80  (as configured in primary\_mail or other\_email in the .notmuch-config\r
81 diff --git a/notmuch-reply.c b/notmuch-reply.c\r
82 index 6df54fc..3c6d685 100644\r
83 --- a/notmuch-reply.c\r
84 +++ b/notmuch-reply.c\r
85 @@ -332,7 +332,7 @@ add_recipients_from_message (GMimeMessage *reply,\r
86       * field and use the From header. This ensures the original sender\r
87       * will get the reply even if not subscribed to the list. Note\r
88       * that the address in the Reply-To header will always appear in\r
89 -     * the reply.\r
90 +     * the reply if reply_all is true.\r
91       */\r
92      if (reply_to_header_is_redundant (message)) {\r
93         reply_to_map[0].header = "from";\r
94 -- \r
95 2.6.4\r
96 \r