[PATCH] test: don't use $(dir) in recipes.
[notmuch-archives.git] / 94 / 1987726d690ba4bf33d5c094f6467c4ec1ad23
1 Return-Path: <awg@xvx.ca>\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 C3F6F431FAF\r
6         for <notmuch@notmuchmail.org>; Sun, 29 Apr 2012 11:17:13 -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.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 s6PIxd1mgfwi for <notmuch@notmuchmail.org>;\r
16         Sun, 29 Apr 2012 11:17:12 -0700 (PDT)\r
17 Received: from mail-lpp01m010-f53.google.com (mail-lpp01m010-f53.google.com\r
18         [209.85.215.53]) (using TLSv1 with cipher RC4-SHA (128/128 bits))\r
19         (No client certificate requested)\r
20         by olra.theworths.org (Postfix) with ESMTPS id 1EE49431FAE\r
21         for <notmuch@notmuchmail.org>; Sun, 29 Apr 2012 11:17:11 -0700 (PDT)\r
22 Received: by lahc1 with SMTP id c1so1684002lah.26\r
23         for <notmuch@notmuchmail.org>; Sun, 29 Apr 2012 11:17:10 -0700 (PDT)\r
24 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;\r
25         d=google.com; s=20120113;\r
26         h=mime-version:sender:x-originating-ip:in-reply-to:references:date\r
27         :x-google-sender-auth:message-id:subject:from:to:cc:content-type\r
28         :content-transfer-encoding:x-gm-message-state;\r
29         bh=zxfDkEFlIHbWBZqIwe2bdZhD/FrXQnv9I+qsdDZuZ84=;\r
30         b=NpdfGZg5RI+5jviP+ypsxfsPohDbqXM5+JHzQrL/oye+8+fU5VA1WNb1Zveb/JG0Au\r
31         K4hBBK18LIJSMoOhlDj7hSynmGHm3qkrh8BwwERRmS3iaPSBaigFz6lT6hgn8SrLQX/h\r
32         +9us5F5Q1iKB5XRGZLQnDzcfj9HAgB51aHHWJ0Q43+lf9fHNMGFNddliUo1rdCcgz4hx\r
33         /ay+b1reK70F0iWLxTehSbZPIjo27JbDiyTpsAhTmEoBWDFOjyYDbKoP1CYXiT7kePDk\r
34         GvzwTfKAJMJ+BKI282zcsJHLaOxeyRVrUJeT47jt7zHVA473zmb/qN232+ihOo0pkh1n\r
35         ZZJQ==\r
36 MIME-Version: 1.0\r
37 Received: by 10.152.133.144 with SMTP id pc16mr17806389lab.0.1335723430378;\r
38         Sun, 29 Apr 2012 11:17:10 -0700 (PDT)\r
39 Sender: awg@xvx.ca\r
40 Received: by 10.112.82.163 with HTTP; Sun, 29 Apr 2012 11:17:10 -0700 (PDT)\r
41 X-Originating-IP: [96.52.216.56]\r
42 In-Reply-To: <87ty02v786.fsf@gmail.com>\r
43 References: <87ty02v786.fsf@gmail.com>\r
44 Date: Sun, 29 Apr 2012 12:17:10 -0600\r
45 X-Google-Sender-Auth: P_5N9wbhFNW71vRouzaFOPZoyYo\r
46 Message-ID:\r
47  <CAMoJFUtY-Dzv8N6gs+8B6c43APqz9J9OSE05eDWLq_tUMEoW3A@mail.gmail.com>\r
48 Subject: Re: [RFC] Use JSON in emacs interface\r
49 From: Adam Wolfe Gordon <awg+notmuch@xvx.ca>\r
50 To: Chris Gray <chrismgray@gmail.com>\r
51 Content-Type: text/plain; charset=ISO-8859-1\r
52 Content-Transfer-Encoding: quoted-printable\r
53 X-Gm-Message-State:\r
54  ALoCoQmd/IywbraIrlPVAFmbiKWdoMPKN57qryulsThNRE+DOjImY9d1T+87vwh5NTJn5QR1ezWC\r
55 Cc: notmuch@notmuchmail.org\r
56 X-BeenThere: notmuch@notmuchmail.org\r
57 X-Mailman-Version: 2.1.13\r
58 Precedence: list\r
59 List-Id: "Use and development of the notmuch mail system."\r
60         <notmuch.notmuchmail.org>\r
61 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
62         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
63 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
64 List-Post: <mailto:notmuch@notmuchmail.org>\r
65 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
66 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
67         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
68 X-List-Received-Date: Sun, 29 Apr 2012 18:17:13 -0000\r
69 \r
70 Hi Chris,\r
71 \r
72 On Sun, Apr 29, 2012 at 10:22, Chris Gray <chrismgray@gmail.com> wrote:\r
73 > I first thought of changing the regex so that it looked for the last\r
74 > semicolon in the string or something like that, but that would just move\r
75 > the problem. =A0(Semicolons are probably more frequent in subject lines\r
76 > than in author names.) =A0So it seems to me that what is needed is for\r
77 > notmuch and emacs to talk with each other in a format that is\r
78 > unambiguously parseable. =A0Since notmuch search already has the option o=\r
79 f\r
80 > outputting to JSON, that seems like a natural fit.\r
81 >\r
82 > Emacs has an existing JSON parser,\r
83 > <http://cvs.savannah.gnu.org/viewvc/*checkout*/emacs/lisp/json.el?root=3D=\r
84 emacs>,\r
85 > but it doesn't appear that it is able to parse progressively, meaning\r
86 > that it wouldn't be able to display results as they come in from notmuch\r
87 > search if used as-is. =A0My guess is that its parts could be hacked\r
88 > together to overcome this limitation though.\r
89 >\r
90 > Anyway, if others think this is a good idea, I'm willing to do the\r
91 > coding.\r
92 \r
93 I think this is a great idea. If you look at notmuch-mua.el and\r
94 notmuch-query.el, you'll see that we already use json.el for reply and\r
95 parts of show.\r
96 \r
97 As for parsing progressively to show search results as they arrive,\r
98 I'd be inclined to instead implement paging, so emacs could ask for\r
99 just the first n results, display them, then ask for the next n\r
100 results, etc. Or maybe ask for the results grouped, so that there\r
101 would be a valid JSON object for the first n results, then another for\r
102 the next n, etc. This might be a tricky thing to design and implement,\r
103 but I think it's been discussed before as something that would be nice\r
104 to have.\r
105 \r
106 Personally, I think it would be fine to implement the JSON search\r
107 first, then deal with progressive parsing and/or grouping, but others\r
108 may differ here. Either way, I'd be happy to review patches for this\r
109 and offer any suggestions.\r
110 \r
111 -- Adam\r