Re: [PATCH v4 0/7] cli: improved crypto internals
[notmuch-archives.git] / 77 / 767a9bdc083bbfb609a87fc6b6f1ded2032597
1 Return-Path: <pieter@praet.org>\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 01E2E41601B\r
6         for <notmuch@notmuchmail.org>; Fri, 24 Feb 2012 14:33:33 -0800 (PST)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: -0.7\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5\r
12         tests=[RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled\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 VvSucD5MqAo7 for <notmuch@notmuchmail.org>;\r
16         Fri, 24 Feb 2012 14:33:31 -0800 (PST)\r
17 Received: from mail-ww0-f45.google.com (mail-ww0-f45.google.com\r
18  [74.125.82.45])        (using TLSv1 with cipher RC4-SHA (128/128 bits))        (No client\r
19  certificate requested) by olra.theworths.org (Postfix) with ESMTPS id\r
20  74DBB415D33    for <notmuch@notmuchmail.org>; Fri, 24 Feb 2012 14:33:30 -0800\r
21  (PST)\r
22 Received: by mail-ww0-f45.google.com with SMTP id dt12so2226566wgb.2\r
23         for <notmuch@notmuchmail.org>; Fri, 24 Feb 2012 14:33:30 -0800 (PST)\r
24 Received-SPF: pass (google.com: domain of pieter@praet.org designates\r
25         10.180.78.6 as permitted sender) client-ip=10.180.78.6; \r
26 Authentication-Results: mr.google.com;\r
27         spf=pass (google.com: domain of pieter@praet.org\r
28         designates 10.180.78.6 as permitted sender)\r
29         smtp.mail=pieter@praet.org\r
30 Received: from mr.google.com ([10.180.78.6])\r
31         by 10.180.78.6 with SMTP id x6mr9059792wiw.18.1330122810212 (num_hops =\r
32         1); Fri, 24 Feb 2012 14:33:30 -0800 (PST)\r
33 MIME-Version: 1.0\r
34 Received: by 10.180.78.6 with SMTP id x6mr7203417wiw.18.1330122810163;\r
35         Fri, 24 Feb 2012 14:33:30 -0800 (PST)\r
36 Received: from localhost ([109.131.181.26])\r
37         by mx.google.com with ESMTPS id fw5sm6322722wib.0.2012.02.24.14.33.29\r
38         (version=TLSv1/SSLv3 cipher=OTHER);\r
39         Fri, 24 Feb 2012 14:33:29 -0800 (PST)\r
40 From: Pieter Praet <pieter@praet.org>\r
41 To: David Bremner <david@tethera.net>,\r
42         Dmitry Kurochkin <dmitry.kurochkin@gmail.com>\r
43 Subject: [PATCH v2 5/6] emacs: simplify `notmuch-show-get-messages-ids{,\r
44         -search}'\r
45 Date: Fri, 24 Feb 2012 23:30:39 +0100\r
46 Message-Id: <1330122640-18895-6-git-send-email-pieter@praet.org>\r
47 X-Mailer: git-send-email 1.7.8.1\r
48 In-Reply-To: <1330122640-18895-1-git-send-email-pieter@praet.org>\r
49 References: <87wr7xqpuf.fsf@rocinante.cs.unb.ca>\r
50         <1330122640-18895-1-git-send-email-pieter@praet.org>\r
51 X-Gm-Message-State:\r
52  ALoCoQnkl5HkH4cNY8FyzGD6qvIaASUz3WPRsQqmpqrT4sq1K5xOpjSmPtanzXFUqXvzrp//iysS\r
53 Cc: Notmuch Mail <notmuch@notmuchmail.org>\r
54 X-BeenThere: notmuch@notmuchmail.org\r
55 X-Mailman-Version: 2.1.13\r
56 Precedence: list\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: Fri, 24 Feb 2012 22:33:33 -0000\r
67 \r
68 * emacs/notmuch-show.el\r
69 \r
70   (notmuch-show-get-messages-ids):\r
71     If provided with optional arg SEPARATOR, return a string consisting\r
72     of all Message-Id's, separated by SEPARATOR.  Also improve original\r
73     docstring wrt default return value.\r
74 \r
75   (notmuch-show-get-messages-ids-search):\r
76     Removed, as its functionality is now in `notmuch-show-get-messages-ids'.\r
77 \r
78   (notmuch-show-tag-all):\r
79     Call `notmuch-show-get-messages-ids' with SEPARATOR arg instead of\r
80     `notmuch-show-get-messages-ids-search'.\r
81 ---\r
82  emacs/notmuch-show.el |   18 +++++++++---------\r
83  1 files changed, 9 insertions(+), 9 deletions(-)\r
84 \r
85 diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el\r
86 index 6adbdc0..05606fc 100644\r
87 --- a/emacs/notmuch-show.el\r
88 +++ b/emacs/notmuch-show.el\r
89 @@ -1339,17 +1339,17 @@ (defun notmuch-show-get-message-id ()\r
90    "Return the message id of the current message."\r
91    (concat "id:\"" (notmuch-show-get-prop :id) "\""))\r
92  \r
93 -(defun notmuch-show-get-messages-ids ()\r
94 -  "Return all message ids of messages in the current thread."\r
95 +(defun notmuch-show-get-messages-ids (&optional separator)\r
96 +  "Return a list of Message-Id's of all messages in the current buffer.\r
97 +\r
98 +If provided with optional argument SEPARATOR, return a string\r
99 +instead, consisting of all Message-Id's separated by SEPARATOR."\r
100    (let ((message-ids))\r
101      (notmuch-show-mapc\r
102       (lambda () (push (notmuch-show-get-message-id) message-ids)))\r
103 -    message-ids))\r
104 -\r
105 -(defun notmuch-show-get-messages-ids-search ()\r
106 -  "Return a search string for all message ids of messages in the\r
107 -current thread."\r
108 -  (mapconcat 'identity (notmuch-show-get-messages-ids) " or "))\r
109 +    (if separator\r
110 +       (mapconcat 'identity message-ids separator)\r
111 +      message-ids)))\r
112  \r
113  ;; dme: Would it make sense to use a macro for many of these?\r
114  \r
115 @@ -1638,7 +1638,7 @@ (defun notmuch-show-tag-all (&rest tag-changes)\r
116  \r
117  TAG-CHANGES is a list of tag operations for `notmuch-tag'."\r
118    (interactive (notmuch-read-tag-changes nil notmuch-show-thread-id))\r
119 -  (apply 'notmuch-tag (notmuch-show-get-messages-ids-search) tag-changes)\r
120 +  (apply 'notmuch-tag (notmuch-show-get-messages-ids " or ") tag-changes)\r
121    (notmuch-show-mapc\r
122     (lambda ()\r
123       (let* ((current-tags (notmuch-show-get-tags))\r
124 -- \r
125 1.7.8.1\r
126 \r