[PATCH] RFC: all deleting all properties with a given key
[notmuch-archives.git] / c6 / ffbd82da3defd30f8df515be6583cd9c83fbf3
1 Return-Path: <jrollins@finestructure.net>\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 5FCF3431FAE\r
6         for <notmuch@notmuchmail.org>; Tue, 23 Feb 2010 13:00:09 -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: -2.286\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=-2.286 tagged_above=-999 required=5\r
12         tests=[AWL=-1.176, BAYES_05=-1.11] autolearn=unavailable\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 6H94i8dLdJzR for <notmuch@notmuchmail.org>;\r
16         Tue, 23 Feb 2010 13:00:09 -0800 (PST)\r
17 Received: from tarap.cc.columbia.edu (tarap.cc.columbia.edu [128.59.29.7])\r
18         by olra.theworths.org (Postfix) with ESMTP id C727D431FBC\r
19         for <notmuch@notmuchmail.org>; Tue, 23 Feb 2010 13:00:08 -0800 (PST)\r
20 Received: from servo.finestructure.net (cpe-72-227-128-66.nyc.res.rr.com\r
21         [72.227.128.66])\r
22         (user=jgr2110 author=jrollins@finestructure.net mech=PLAIN bits=0)\r
23         by tarap.cc.columbia.edu (8.14.3/8.14.3) with ESMTP id o1NL05wt022361\r
24         (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NOT);\r
25         Tue, 23 Feb 2010 16:00:05 -0500 (EST)\r
26 Received: from jrollins by servo.finestructure.net with local (Exim 4.71)\r
27         (envelope-from <jrollins@finestructure.net>)\r
28         id 1Nk1rR-00068N-2F; Tue, 23 Feb 2010 16:00:05 -0500\r
29 From: Jameson Rollins <jrollins@finestructure.net>\r
30 To: Carl Worth <cworth@cworth.org>, david@tethera.net, notmuch@notmuchmail.org\r
31 In-Reply-To: <878wajwwth.fsf@yoom.home.cworth.org>\r
32 References: <1261114167-sup-8228@lisa>\r
33         <1261141195-5469-1-git-send-email-david@tethera.net>\r
34         <878wajwwth.fsf@yoom.home.cworth.org>\r
35 Date: Tue, 23 Feb 2010 16:00:01 -0500\r
36 Message-ID: <87wry33bxq.fsf@servo.finestructure.net>\r
37 MIME-Version: 1.0\r
38 Content-Type: multipart/signed; boundary="=-=-=";\r
39         micalg=pgp-sha256; protocol="application/pgp-signature"\r
40 X-No-Spam-Score: Local\r
41 X-Scanned-By: MIMEDefang 2.68 on 128.59.29.7\r
42 Subject: [notmuch] JSON output as default [was: Re: [PATCH] Add an\r
43         "--output=(json|text|)" command-line option...]\r
44 X-BeenThere: notmuch@notmuchmail.org\r
45 X-Mailman-Version: 2.1.13\r
46 Precedence: list\r
47 List-Id: "Use and development of the notmuch mail system."\r
48         <notmuch.notmuchmail.org>\r
49 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
50         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
51 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
52 List-Post: <mailto:notmuch@notmuchmail.org>\r
53 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
54 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
55         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
56 X-List-Received-Date: Tue, 23 Feb 2010 21:00:09 -0000\r
57 \r
58 --=-=-=\r
59 \r
60 Hey, Carl.  I mentioned this is an email a while back\r
61 (id:87eil4ygar.fsf@servo.finestructure.net), but I want to bring it up\r
62 again now that you're looking at the JSON output stuff.  I would like to\r
63 make the case for JSON being the one and only output format.  Here's the\r
64 arguments:\r
65 \r
66 * JSON is a very well spec'd API\r
67 * JSON is a *very* well supported standard (it's basically well\r
68   supported by every language)\r
69 * the JSONformat is perfectly suited for notmuch's output\r
70 * emacs has a json.el library, so it would not be hard at all to modify\r
71   the notmuch.el to parse json output\r
72 * using only one output format would considerably reduce the code base\r
73   in notmuch, keeping things simpler and easier to maintain\r
74 \r
75 I think these are pretty good reason to just move to JSON as *the*\r
76 output format.\r
77 \r
78 While I'm on this topic, let me rehash another point I made previously:\r
79 If we move to JSON output, it would be *so* sweet to provide means to\r
80 filter the output JSON fields.  The "--output" flag could be used to\r
81 pick the desired output fields.  For instance, the current "search"\r
82 output could be something like:\r
83 \r
84 search --output=thread_id,date,number,author,subject,tags\r
85 \r
86 while the current "show" output could be something like:\r
87 \r
88 search --output=message_id,tags,path,header,body,attachments\r
89 \r
90 This would all make things *much* easier for clients and wrappers.  For\r
91 instance, here are just a couple of things that would be made much\r
92 easier for wrapper scripts:\r
93 \r
94 * Proper maildir sync ("search --output=message_id,tags,path" ...)\r
95 \r
96 * Purging "delete" tagged messages ("search --output=path" tags:delete)\r
97 \r
98 * Moving/archiving messages based on search results ("search --output=path" ...)\r
99 \r
100 I would personally love to see this.  I think it would make notmuch\r
101 cleaner, simpler, and more powerful all at the same time.\r
102 \r
103 Interested in hearing what other's thoughts on this idea are.\r
104 \r
105 jamie.\r
106 \r
107 --=-=-=\r
108 Content-Type: application/pgp-signature\r
109 \r
110 -----BEGIN PGP SIGNATURE-----\r
111 Version: GnuPG v1.4.10 (GNU/Linux)\r
112 \r
113 iQIcBAEBCAAGBQJLhEHSAAoJEO00zqvie6q8sFAP/jpVK6AOhAle5+4MZQqpn1eG\r
114 H4Be0N8brsNAeM4o6JvTW7XHdV7O2u/wwGTq2lmoxwF0slcmKjVcWHr7QP7VrvlV\r
115 P7iXyfb3A94pjaMldzgtKW5OZ3/a/lE3yPYffBaJ4rcuHcSI/mlugVzy7v4UZ8ep\r
116 T0h2kE9B36014YpZklzWpHu1kfj79y0Y2u8ZDRTYWK9mAInLVTsF8zLIYcrfRrDR\r
117 wH7WIahtpwye9LeL6oB8Kqi4KfB0MUPvyML80CAu3FiaCd/RA1ij/KUb3JbE2Wf4\r
118 D1DAEVnZIxc/WgxGJnoisHM9kSuMAv7pgvxoqlpnxi1cZhL4xGvmlKf7QhgbpyMQ\r
119 2JYUvNzRmNndJJGyoMByS2o/KfADkK1ML/TryodYPAI3tkimy+ZL/cN7F1yH1cqp\r
120 htUNfJfuTlGEFVpAl/8QMvvRUmTRInKe0MFrr3941FrRc33GZ92qUgUB15v3K6NG\r
121 wMg+8pdUPe9r/mY8PyyjWzrqowwIINmexFzzLhNRSG1MnrPoJzk410L3xmnkDKz9\r
122 jaIx1bMrHOOa1QMwfC8oou1xSJjqE1Sld7kygUgbnw9c7pdhh3ZdXfS4BXQmJXNz\r
123 gXqtHLWBKs7UQ0Ow7zXyqq23+big1QQy1Xe1ViIDBKwTY4momwQ1szu0zeHPE1BL\r
124 p32Sfd09W/tE4KNnJKe4\r
125 =t2XF\r
126 -----END PGP SIGNATURE-----\r
127 --=-=-=--\r