encrypting replies to encrypted mail
[notmuch-archives.git] / be / a70a3b6f5d2dd4010a3eff86b580f9bface2cf
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 38000431FAF\r
6         for <notmuch@notmuchmail.org>; Thu,  6 Sep 2012 07:30:50 -0700 (PDT)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: 0\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none]\r
12         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 I4tFRUlP-Don for <notmuch@notmuchmail.org>;\r
16         Thu,  6 Sep 2012 07:30:49 -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 8B840431FAE\r
19         for <notmuch@notmuchmail.org>; Thu,  6 Sep 2012 07:30:49 -0700 (PDT)\r
20 Received: from guru.guru-group.fi (localhost [IPv6:::1])\r
21         by guru.guru-group.fi (Postfix) with ESMTP id 0F8A51000E5;\r
22         Thu,  6 Sep 2012 17:30:57 +0300 (EEST)\r
23 From: Tomi Ollila <tomi.ollila@iki.fi>\r
24 To: Jani Nikula <jani@nikula.org>, Michal Nazarewicz <mina86@mina86.com>,\r
25         notmuch@notmuchmail.org\r
26 Subject: Re: [PATCH 1/6] emacs: add helper for tag change list manipulation\r
27 In-Reply-To: <87txvf8g5b.fsf@nikula.org>\r
28 References: <cover.1346614915.git.jani@nikula.org>\r
29         <9dbf16fb95f40812ad246f95b954681bc895ceb2.1346614915.git.jani@nikula.org>\r
30         <xa1tipbvwdb0.fsf@mina86.com> <87txvf8g5b.fsf@nikula.org>\r
31 User-Agent: Notmuch/0.14+11~gd9bf007 (http://notmuchmail.org) Emacs/24.2.1\r
32         (x86_64-unknown-linux-gnu)\r
33 X-Face: HhBM'cA~<r"^Xv\KRN0P{vn'Y"Kd;zg_y3S[4)KSN~s?O\"QPoL\r
34         $[Xv_BD:i/F$WiEWax}R(MPS`^UaptOGD`*/=@\1lKoVa9tnrg0TW?"r7aRtgk[F\r
35         !)g;OY^,BjTbr)Np:%c_o'jj,Z\r
36 Date: Thu, 06 Sep 2012 17:30:56 +0300\r
37 Message-ID: <m2obljxly7.fsf@guru.guru-group.fi>\r
38 MIME-Version: 1.0\r
39 Content-Type: text/plain; charset=utf-8\r
40 Content-Transfer-Encoding: quoted-printable\r
41 X-BeenThere: notmuch@notmuchmail.org\r
42 X-Mailman-Version: 2.1.13\r
43 Precedence: list\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: Thu, 06 Sep 2012 14:30:50 -0000\r
54 \r
55 On Mon, Sep 03 2012, Jani Nikula wrote:\r
56 \r
57 > On Mon, 03 Sep 2012, Michal Nazarewicz <mina86@mina86.com> wrote:\r
58 >> Jani Nikula <jani@nikula.org> writes:\r
59 >>> Add a helper to create (and optionally reverse) a list of tag changes.\r
60 >>> ---\r
61 >>>  emacs/notmuch-tag.el |   17 +++++++++++++++++\r
62 >>>  1 file changed, 17 insertions(+)\r
63 >>>\r
64 >>> diff --git a/emacs/notmuch-tag.el b/emacs/notmuch-tag.el\r
65 >>> index 0c0fc87..c1aeb99 100644\r
66 >>> --- a/emacs/notmuch-tag.el\r
67 >>> +++ b/emacs/notmuch-tag.el\r
68 >>> @@ -140,6 +140,23 @@ notmuch-after-tag-hook will be run."\r
69 >>>    ;; in all cases we return tag-changes as a list\r
70 >>>    tag-changes)\r
71 >>>=20=20\r
72 >>> +(defun notmuch-tag-change-list (tags &optional reverse)\r
73 >>> +  "Convert TAGS into a list of tag changes.\r
74 >>> +\r
75 >>> +Add a \"+\" prefix to any tag in TAGS list that doesn't already\r
76 >>> +begin with a \"+\" or a \"-\". If REVERSE is non-nil, replace all\r
77 >>> +\"+\" prefixes with \"-\" and vice versa in the result."\r
78 >>> +  (mapcar (lambda (str)\r
79 >>> +       (let ((s (if (not (string-match "^[+-]" str))\r
80 >>> +                    (concat "+" str)\r
81 >>> +                  str)))\r
82 >>\r
83 >> (if (string-match "^[-+]" str) str (concat "+" str))\r
84 >>\r
85 >> Negation only makes things less readable IMO.\r
86 >\r
87 > Agreed.\r
88 \r
89 The whole series LGTM -- but are you still going to do=20\r
90 changes here ?\r
91 \r
92 > Jani.\r
93 \r
94 Tomi\r
95 \r
96 \r
97 >\r
98 >>\r
99 >>> +         (if reverse\r
100 >>> +             (concat (if (=3D (string-to-char s) ?-) "+" "-")\r
101 >>> +                     (substring s 1))\r
102 >>> +           s)))\r
103 >>> +     tags))\r
104 >>> +\r
105 >>> +\r
106 >>>  ;;\r
107 >>>=20=20\r
108 >>>  (provide 'notmuch-tag)\r
109 >>\r
110 >> --=20\r
111 >> Best regards,                                         _     _\r
112 >> .o. | Liege of Serenely Enlightened Majesty of      o' \,=3D./ `o\r
113 >> ..o | Computer Science,  Micha=C5=82 =E2=80=9Cmina86=E2=80=9D Nazarewicz=\r
114     (o o)\r
115 >> ooo +----<email/xmpp: mpn@google.com>--------------ooO--(_)--Ooo--\r