Re: Hi all
[notmuch-archives.git] / e5 / 608751fcf9e9569441e6e80f47783a7dc93d13
1 Return-Path: <david@tethera.net>\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 8B4AD6DE1104\r
6  for <notmuch@notmuchmail.org>; Mon,  9 Nov 2015 04:18:53 -0800 (PST)\r
7 X-Virus-Scanned: Debian amavisd-new at cworth.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: 0.095\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=0.095 tagged_above=-999 required=5 tests=[AWL=0.095]\r
12  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 uJrmbH8EZxv4 for <notmuch@notmuchmail.org>;\r
16  Mon,  9 Nov 2015 04:18:51 -0800 (PST)\r
17 Received: from gitolite.debian.net (gitolite.debian.net [87.98.215.224])\r
18  by arlo.cworth.org (Postfix) with ESMTPS id 0703C6DE103A\r
19  for <notmuch@notmuchmail.org>; Mon,  9 Nov 2015 04:18:51 -0800 (PST)\r
20 Received: from remotemail by gitolite.debian.net with local (Exim 4.80)\r
21  (envelope-from <david@tethera.net>)\r
22  id 1ZvlOd-0005o5-83; Mon, 09 Nov 2015 12:18:03 +0000\r
23 Received: (nullmailer pid 22982 invoked by uid 1000); Mon, 09 Nov 2015\r
24  12:17:44 -0000\r
25 From: David Bremner <david@tethera.net>\r
26 To: Michal Sojka <sojkam1@fel.cvut.cz>, notmuch@notmuchmail.org\r
27 Subject: Re: [PATCH] emacs: Fix regression in (notmuch-)message-mode\r
28  initialization\r
29 In-Reply-To: <1446573161-28068-1-git-send-email-sojkam1@fel.cvut.cz>\r
30 References: <1446573161-28068-1-git-send-email-sojkam1@fel.cvut.cz>\r
31 User-Agent: Notmuch/0.21~rc3+7~g10e933a (http://notmuchmail.org) Emacs/24.5.1\r
32  (x86_64-pc-linux-gnu)\r
33 Date: Mon, 09 Nov 2015 08:17:44 -0400\r
34 Message-ID: <87d1vj4b9z.fsf@zancas.localnet>\r
35 MIME-Version: 1.0\r
36 Content-Type: text/plain\r
37 X-BeenThere: notmuch@notmuchmail.org\r
38 X-Mailman-Version: 2.1.20\r
39 Precedence: list\r
40 List-Id: "Use and development of the notmuch mail system."\r
41  <notmuch.notmuchmail.org>\r
42 List-Unsubscribe: <https://notmuchmail.org/mailman/options/notmuch>,\r
43  <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
44 List-Archive: <http://notmuchmail.org/pipermail/notmuch/>\r
45 List-Post: <mailto:notmuch@notmuchmail.org>\r
46 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
47 List-Subscribe: <https://notmuchmail.org/mailman/listinfo/notmuch>,\r
48  <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
49 X-List-Received-Date: Mon, 09 Nov 2015 12:18:53 -0000\r
50 \r
51 Michal Sojka <sojkam1@fel.cvut.cz> writes:\r
52 \r
53 > This commit uses advice mechanism to call notmuch-message-mode instead\r
54 > of message-mode. This way, a call to message-mail initializes directly\r
55 > notmuch-message-mode rather than message-mode which is later changed\r
56 > to notmuch-message-mode. The advice is constructed in such a way, that\r
57 > it is effective only once and when called by notmuch. The second call\r
58 > to message-mode (from notmuch-message-mode) calls the original\r
59 > message-mode.\r
60 \r
61 I wanted to answer this with an alternative patch, but I haven't had\r
62 time.\r
63 \r
64 I admit to being somewhat prejudiced against shipping code with advice\r
65 in it (IMHO it's fine for user specific customization, but not very\r
66 maintainable).\r
67 \r
68 I think we might be better off in the long run replacing the call to\r
69 message-mail. Code duplication is obviously not great, but perhaps some\r
70 of the complexity of message-mail / message-pop-to-buffer can be\r
71 eliminated, since we don't need to support all of the use cases of\r
72 message-mail.\r
73 \r
74 > This implementation uses the new advice mechanism introduced in Emacs\r
75 > 24.4. If we want to support older version, this must be changed.\r
76 \r
77 We do try to support Emacs 23 still (except for some optional\r
78 features). Unfortunately old advice is even nastier.\r
79 \r
80 d\r
81 \r