Re: [PATCH v4 01/16] add util/search-path.{c, h} to test for executables in $PATH
[notmuch-archives.git] / 1d / 905236f0de753184c9c8490f50f852ed933bc4
1 Return-Path: <m.walters@qmul.ac.uk>\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 14F79431FDC\r
6         for <notmuch@notmuchmail.org>; Tue,  6 May 2014 04:08:37 -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.502\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=0.502 tagged_above=-999 required=5\r
12         tests=[DKIM_ADSP_CUSTOM_MED=0.001, FREEMAIL_FROM=0.001,\r
13         NML_ADSP_CUSTOM_MED=1.2, RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled\r
14 Received: from olra.theworths.org ([127.0.0.1])\r
15         by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
16         with ESMTP id 7vrP7idlSLw8 for <notmuch@notmuchmail.org>;\r
17         Tue,  6 May 2014 04:08:29 -0700 (PDT)\r
18 Received: from mail1.qmul.ac.uk (mail1.qmul.ac.uk [138.37.6.7])\r
19         (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits))\r
20         (No client certificate requested)\r
21         by olra.theworths.org (Postfix) with ESMTPS id 5C5C3431FD6\r
22         for <notmuch@notmuchmail.org>; Tue,  6 May 2014 04:08:29 -0700 (PDT)\r
23 Received: from smtp.qmul.ac.uk ([138.37.6.40])\r
24         by mail1.qmul.ac.uk with esmtp (Exim 4.71)\r
25         (envelope-from <m.walters@qmul.ac.uk>)\r
26         id 1WhdEU-00010G-J6; Tue, 06 May 2014 12:08:25 +0100\r
27 Received: from 5751dfa2.skybroadband.com ([87.81.223.162] helo=localhost)\r
28         by smtp.qmul.ac.uk with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.71)\r
29         (envelope-from <m.walters@qmul.ac.uk>)\r
30         id 1WhdEU-0002Uq-Bq; Tue, 06 May 2014 12:08:22 +0100\r
31 From: Mark Walters <markwalters1009@gmail.com>\r
32 To: 'Mash <subscribe@toshine.net>, notmuch@notmuchmail.org\r
33 Subject: Re: Notmuch-tree add/remove/toggle tag\r
34 In-Reply-To: <20140506113931.75041t5v5q33pvr4@webmail.tuffmail.net>\r
35 References: <20140506113931.75041t5v5q33pvr4@webmail.tuffmail.net>\r
36 User-Agent: Notmuch/0.15.2+615~g78e3a93 (http://notmuchmail.org) Emacs/23.4.1\r
37         (i486-pc-linux-gnu)\r
38 Date: Tue, 06 May 2014 12:08:21 +0100\r
39 Message-ID: <87oazbcggq.fsf@qmul.ac.uk>\r
40 MIME-Version: 1.0\r
41 Content-Type: text/plain; charset=us-ascii\r
42 X-Sender-Host-Address: 87.81.223.162\r
43 X-QM-Geographic: According to ripencc,\r
44         this message was delivered by a machine in Britain (UK) (GB).\r
45 X-QM-SPAM-Info: Sender has good ham record.  :)\r
46 X-QM-Body-MD5: e4f0e751e2b5cce1bca23ace15e3e240 (of first 20000 bytes)\r
47 X-SpamAssassin-Score: -0.1\r
48 X-SpamAssassin-SpamBar: /\r
49 X-SpamAssassin-Report: The QM spam filters have analysed this message to\r
50         determine if it is\r
51         spam. We require at least 5.0 points to mark a message as spam.\r
52         This message scored -0.1 points.\r
53         Summary of the scoring: \r
54         * 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail\r
55         provider *      (markwalters1009[at]gmail.com)\r
56         * -0.1 AWL AWL: From: address is in the auto white-list\r
57 X-QM-Scan-Virus: ClamAV says the message is clean\r
58 X-BeenThere: notmuch@notmuchmail.org\r
59 X-Mailman-Version: 2.1.13\r
60 Precedence: list\r
61 List-Id: "Use and development of the notmuch mail system."\r
62         <notmuch.notmuchmail.org>\r
63 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
64         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
65 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
66 List-Post: <mailto:notmuch@notmuchmail.org>\r
67 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
68 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
69         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
70 X-List-Received-Date: Tue, 06 May 2014 11:08:37 -0000\r
71 \r
72 'Mash <subscribe@toshine.net> writes:\r
73 \r
74 > I am trying to setup a tag toggle to be used in the Notmuch-tree.\r
75 >\r
76 > I referred to "Add a key binding to add/remove/toggle a tag":  \r
77 > http://notmuchmail.org/emacstips/#index8h2\r
78 >\r
79 > Looking at "notmuch-tree.el" I noticed\r
80 >\r
81 > (defun notmuch-tree-get-tags ()\r
82 >    "Return the tags of the current message."\r
83 >    (notmuch-tree-get-prop :tags))\r
84 >\r
85 > and\r
86 >\r
87 > (defun notmuch-tree-tag (tag-changes)\r
88 >    "Change tags for the current message"\r
89 >    (interactive\r
90 >     (list (notmuch-read-tag-changes (notmuch-tree-get-tags) "Tag message")))\r
91 >    (notmuch-tag (notmuch-tree-get-message-id) tag-changes)\r
92 >    (notmuch-tree-tag-update-display tag-changes))\r
93 >\r
94 > Which in my mind would be substituted for "notmuch-show-tag-message"  \r
95 > and "notmuch-show-get-tags" respectively in the "add a toggle  \r
96 > "deleted" key" example.\r
97 >\r
98 > (define-key notmuch-tree-mode-map "d"\r
99 >    (lambda ()\r
100 >      "toggle deleted tag for message"\r
101 >      (interactive)\r
102 >      (notmuch-tree-tag\r
103 >       (if (member "deleted" (notmuch-tree-get-tags))\r
104 >           "-deleted" "+deleted"))))\r
105 \r
106 Hi\r
107 \r
108 I think you want \r
109 \r
110        (if (member "deleted" (notmuch-tree-get-tags))\r
111            (list "-deleted")\r
112          (list "+deleted")))))\r
113 \r
114 at the end. It looks like the wiki could do some tidying, which I will\r
115 try and have  a look at at some point.\r
116 \r
117 Best wishes\r
118 \r
119 Mark\r
120 \r
121 >\r
122 > The problem is that in notmuch-tree when I get the following message:  \r
123 > "Entering debugger... button-at: Args out of range: 0" and the tag  \r
124 > fails to be toggled.\r
125 >\r
126 > Not quite sure where I am going wrong here?\r
127 >\r
128 > Thanks,\r
129 >\r
130 >\r
131 > _______________________________________________\r
132 > notmuch mailing list\r
133 > notmuch@notmuchmail.org\r
134 > http://notmuchmail.org/mailman/listinfo/notmuch\r