1 Return-Path: <Sebastian@SSpaeth.de>
\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 86CCA4196F4
\r
6 for <notmuch@notmuchmail.org>; Tue, 6 Apr 2010 00:12:56 -0700 (PDT)
\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org
\r
11 X-Spam-Status: No, score=-1.9 tagged_above=-999 required=5
\r
12 tests=[BAYES_00=-1.9] autolearn=ham
\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 8LooBS3yXlrK for <notmuch@notmuchmail.org>;
\r
16 Tue, 6 Apr 2010 00:12:55 -0700 (PDT)
\r
17 Received: from homiemail-a19.g.dreamhost.com (caiajhbdcbef.dreamhost.com
\r
19 by olra.theworths.org (Postfix) with ESMTP id B16484196F5
\r
20 for <notmuch@notmuchmail.org>; Tue, 6 Apr 2010 00:12:55 -0700 (PDT)
\r
21 Received: from localhost.localdomain (mtec-hg-docking-1-dhcp-204.ethz.ch
\r
23 by homiemail-a19.g.dreamhost.com (Postfix) with ESMTPA id 5746260406C;
\r
24 Tue, 6 Apr 2010 00:12:54 -0700 (PDT)
\r
25 From: Sebastian Spaeth <Sebastian@SSpaeth.de>
\r
26 To: notmuch@notmuchmail.org
\r
27 Subject: [PATCH 2/2] notmuch.el: Add support for reply-to sender
\r
28 Date: Tue, 6 Apr 2010 09:12:46 +0200
\r
29 Message-Id: <1270537966-19324-2-git-send-email-Sebastian@SSpaeth.de>
\r
30 X-Mailer: git-send-email 1.6.3.3
\r
31 In-Reply-To: <1270537966-19324-1-git-send-email-Sebastian@SSpaeth.de>
\r
32 References: <87mxxhgims.fsf@SSpaeth.de>
\r
33 <1270537966-19324-1-git-send-email-Sebastian@SSpaeth.de>
\r
34 Cc: "Aneesh Kumar K.V" <aneesh.kumar@gmail.com>
\r
35 X-BeenThere: notmuch@notmuchmail.org
\r
36 X-Mailman-Version: 2.1.13
\r
38 List-Id: "Use and development of the notmuch mail system."
\r
39 <notmuch.notmuchmail.org>
\r
40 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,
\r
41 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
42 List-Archive: <http://notmuchmail.org/pipermail/notmuch>
\r
43 List-Post: <mailto:notmuch@notmuchmail.org>
\r
44 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
45 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,
\r
46 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
47 X-List-Received-Date: Tue, 06 Apr 2010 07:12:56 -0000
\r
49 From: Aneesh Kumar K.V <aneesh.kumar@gmail.com>
\r
51 Add key binding to do a reply-to sender. This is mapped to 'R'
\r
53 Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@gmail.com>
\r
54 Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
\r
56 emacs/notmuch-show.el | 21 ++++++++++++++++++++-
\r
57 1 files changed, 20 insertions(+), 1 deletions(-)
\r
59 diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el
\r
60 index cc1f905..3d89861 100644
\r
61 --- a/emacs/notmuch-show.el
\r
62 +++ b/emacs/notmuch-show.el
\r
64 (define-key map "s" 'notmuch-search)
\r
65 (define-key map "m" 'message-mail)
\r
66 (define-key map "f" 'notmuch-show-forward-current)
\r
67 - (define-key map "r" 'notmuch-show-reply)
\r
68 + (define-key map "r" 'notmuch-show-reply-all)
\r
69 + (define-key map "R" 'notmuch-show-reply)
\r
70 (define-key map "|" 'notmuch-show-pipe-message)
\r
71 (define-key map "w" 'notmuch-show-save-attachments)
\r
72 (define-key map "V" 'notmuch-show-view-raw-message)
\r
73 @@ -360,10 +361,28 @@ buffer."
\r
74 mm-handle (> (notmuch-count-attachments mm-handle) 1))))
\r
77 +(defun notmuch-recipient-reply (recipient query-string)
\r
78 + (switch-to-buffer (generate-new-buffer "notmuch-draft"))
\r
79 + (call-process notmuch-command nil t nil "reply"
\r
80 + (concat "--recipient=" recipient) query-string)
\r
81 + (message-insert-signature)
\r
82 + (goto-char (point-min))
\r
83 + (if (re-search-forward "^$" nil t)
\r
85 + (insert "--text follows this line--")
\r
89 (defun notmuch-show-reply ()
\r
90 "Begin composing a reply to the current message in a new buffer."
\r
92 (let ((message-id (notmuch-show-get-message-id)))
\r
93 + (notmuch-recipient-reply "sender" message-id)))
\r
95 +(defun notmuch-show-reply-all ()
\r
96 + "Begin composing a reply to the current message in a new buffer."
\r
98 + (let ((message-id (notmuch-show-get-message-id)))
\r
99 (notmuch-reply message-id)))
\r
101 (defun notmuch-show-forward-current ()
\r