Re: [feature request] emacs: use `notmuch insert` for FCC
[notmuch-archives.git] / 18 / ffc2e7b8fbb61565b1c2f60184b231e2d8806d
1 Return-Path: <amdragon@gmail.com>\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 C550240DDC2\r
6         for <notmuch@notmuchmail.org>; Sun, 21 Nov 2010 09:36:00 -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: -1.998\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=-1.998 tagged_above=-999 required=5\r
12         tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1,\r
13         DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001,\r
14         RCVD_IN_DNSWL_NONE=-0.0001] autolearn=ham\r
15 Received: from olra.theworths.org ([127.0.0.1])\r
16         by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
17         with ESMTP id d0RRnDW28ebY for <notmuch@notmuchmail.org>;\r
18         Sun, 21 Nov 2010 09:35:50 -0800 (PST)\r
19 Received: from mail-qw0-f53.google.com (mail-qw0-f53.google.com\r
20         [209.85.216.53])\r
21         by olra.theworths.org (Postfix) with ESMTP id 03AC240DF1F\r
22         for <notmuch@notmuchmail.org>; Sun, 21 Nov 2010 09:35:49 -0800 (PST)\r
23 Received: by qwd7 with SMTP id 7so1644291qwd.26\r
24         for <notmuch@notmuchmail.org>; Sun, 21 Nov 2010 09:35:47 -0800 (PST)\r
25 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma;\r
26         h=domainkey-signature:mime-version:received:received:in-reply-to\r
27         :references:date:message-id:subject:from:to:cc:content-type;\r
28         bh=Q4p+52QEleAGZwy7r8Li8yGJigiaLZMZbFneszAIThE=;\r
29         b=LMSJaalOD2UgsZsqlNjTsuI0F4H11xdLQBDpqS8vvC6692zr4mdmDUncw/q7XdVX6Q\r
30         XvEhujmKsdHowvk47aSr6GbcM9TmADjXQ5/+2fpOwZAbaXu1FJVcAh4iAopO9pRbpC7T\r
31         W9HTUZ+DUYuxD7DuLY1zzeF4gAa0gp3/rx2nU=\r
32 DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma;\r
33         h=mime-version:in-reply-to:references:date:message-id:subject:from:to\r
34         :cc:content-type;\r
35         b=pG6dg5Q3AbKQ8jdSoMB0tOuHhaoXfPp0fo7wKRT+50mVTIC+BbLVNpXDl+Uf70LxVH\r
36         PeSGCqkAqIVuuNZEXFJ1MaK5HedROiA3RdN6oWV6T3zqU6nougAExfuhyRUYNB0Giip/\r
37         PTl8gO3biJq/GvI+8caj8+cSDRPS1B+Dm9V0s=\r
38 MIME-Version: 1.0\r
39 Received: by 10.229.189.20 with SMTP id dc20mr4282247qcb.125.1290360947378;\r
40         Sun, 21 Nov 2010 09:35:47 -0800 (PST)\r
41 Received: by 10.229.224.202 with HTTP; Sun, 21 Nov 2010 09:35:47 -0800 (PST)\r
42 In-Reply-To: <AANLkTin_6A1qnuFpE9oPXySA0j5jTV-tq=BbqSNMPWfb@mail.gmail.com>\r
43 References: <AANLkTi=7eCt0=NqUiJFrGDcaZ17LOd3qNNqN1-ASwYzr@mail.gmail.com>\r
44         <87sjyvk875.fsf@wsheee.2x.cz>\r
45         <AANLkTin_6A1qnuFpE9oPXySA0j5jTV-tq=BbqSNMPWfb@mail.gmail.com>\r
46 Date: Sun, 21 Nov 2010 12:35:47 -0500\r
47 Message-ID: <AANLkTikMUhmEQjSLj3Uys9iBU1r8G22TuT337y1N3ZrJ@mail.gmail.com>\r
48 Subject: Re: [PATCH] Implement a simple read-eval-print loop.\r
49 From: Austin Clements <amdragon@gmail.com>\r
50 To: servilio <servilio@gmail.com>\r
51 Content-Type: multipart/alternative; boundary=0016362842dee68c950495939126\r
52 Cc: notmuch <notmuch@notmuchmail.org>\r
53 X-BeenThere: notmuch@notmuchmail.org\r
54 X-Mailman-Version: 2.1.13\r
55 Precedence: list\r
56 List-Id: "Use and development of the notmuch mail system."\r
57         <notmuch.notmuchmail.org>\r
58 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
59         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
60 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
61 List-Post: <mailto:notmuch@notmuchmail.org>\r
62 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
63 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
64         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
65 X-List-Received-Date: Sun, 21 Nov 2010 17:36:00 -0000\r
66 \r
67 --0016362842dee68c950495939126\r
68 Content-Type: text/plain; charset=ISO-8859-1\r
69 \r
70 Out of curiosity, why not simply use SSH control mastering?  You could even\r
71 make that part of the "standard" remote notmuch script, without requiring\r
72 the user to change anything in their ssh configuration.  This should be just\r
73 as fast as a remote notmuch shell, but retains the ability to run multiple\r
74 simultaneous operations and leverages all of the fancy session machinery\r
75 already built in to ssh.  It seems to me that ssh already does what you\r
76 want, and I'm curious what the advantage is to reinventing the wheel.\r
77 \r
78 On Sat, Nov 20, 2010 at 6:38 PM, servilio <servilio@gmail.com> wrote:\r
79 \r
80 > Hi Michal,\r
81 >\r
82 > On 20 November 2010 16:15, Michal Sojka <sojkam1@fel.cvut.cz> wrote:\r
83 > > On Sat, 20 Nov 2010, servilio wrote:\r
84 > >> This implementation uses GNU readline for the prompt and command\r
85 > >> history, with the default file completion enabled. GLib is used to\r
86 > >> split the read line into an arguments list.\r
87 > >\r
88 > > Hi,\r
89 > >\r
90 > > I haven't tested it yet, but it seems to be exactly the piece of code I\r
91 > > wanted to have to speed up notmuch-hello when notmuch is used remotely\r
92 > > over ssh. Spawning new ssh for every saved search to get the count of\r
93 > > matched messages has a way too big overhead. Is this the use case you\r
94 > > had in mind when implementing this?\r
95 >\r
96 > Great to see that you find it useful. Yes, the remote usage was in my\r
97 > mind, but it should enhance the local usage as well. We could also\r
98 > create a quicker test run using the shell.\r
99 >\r
100 > The disadvantage of using an interactive shell is that you can have\r
101 > only one operation running in the UI, and I see no way of\r
102 > interrumpting an operation unless you kill the process, but as\r
103 > starting a new shell shouldn't be a biggie, this might not be as\r
104 > limiting as might seem.\r
105 >\r
106 > The ideal would be for libnotmuch to be able to connect to a\r
107 > xapian-tcpsrv, but haven't had time to look at than, and an\r
108 > interactive shell seemed to be less time demanding to implement (and\r
109 > had the subjective promise of providing a lot of fun).\r
110 >\r
111 > > Currently, I have only one comment to the patch. For me, "repl" is a bit\r
112 > > unintuitive. I was thinking about "shell" as the name of subcommand for\r
113 > > this.\r
114 >\r
115 > I agree, maybe "shell" or "interactive" would be more intuitive, but\r
116 > when I started "repl" was the only one I could think of.\r
117 >\r
118 > Servilio\r
119 > _______________________________________________\r
120 > notmuch mailing list\r
121 > notmuch@notmuchmail.org\r
122 > http://notmuchmail.org/mailman/listinfo/notmuch\r
123 >\r
124 \r
125 --0016362842dee68c950495939126\r
126 Content-Type: text/html; charset=ISO-8859-1\r
127 Content-Transfer-Encoding: quoted-printable\r
128 \r
129 Out of curiosity, why not simply use SSH control mastering? =A0You could ev=\r
130 en make that part of the &quot;standard&quot; remote notmuch script, withou=\r
131 t requiring the user to change anything in their ssh configuration. =A0This=\r
132  should be just as fast as a remote notmuch shell, but retains the ability =\r
133 to run multiple simultaneous operations and leverages all of the fancy sess=\r
134 ion machinery already built in to ssh. =A0It seems to me that ssh already d=\r
135 oes what you want, and I&#39;m curious what the advantage is to reinventing=\r
136  the wheel.<div>\r
137 <br><div class=3D"gmail_quote">On Sat, Nov 20, 2010 at 6:38 PM, servilio <s=\r
138 pan dir=3D"ltr">&lt;<a href=3D"mailto:servilio@gmail.com">servilio@gmail.co=\r
139 m</a>&gt;</span> wrote:<br><blockquote class=3D"gmail_quote" style=3D"margi=\r
140 n:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">\r
141 Hi Michal,<br>\r
142 <div class=3D"im"><br>\r
143 On 20 November 2010 16:15, Michal Sojka &lt;<a href=3D"mailto:sojkam1@fel.c=\r
144 vut.cz">sojkam1@fel.cvut.cz</a>&gt; wrote:<br>\r
145 &gt; On Sat, 20 Nov 2010, servilio wrote:<br>\r
146 &gt;&gt; This implementation uses GNU readline for the prompt and command<b=\r
147 r>\r
148 &gt;&gt; history, with the default file completion enabled. GLib is used to=\r
149 <br>\r
150 &gt;&gt; split the read line into an arguments list.<br>\r
151 &gt;<br>\r
152 &gt; Hi,<br>\r
153 &gt;<br>\r
154 &gt; I haven&#39;t tested it yet, but it seems to be exactly the piece of c=\r
155 ode I<br>\r
156 &gt; wanted to have to speed up notmuch-hello when notmuch is used remotely=\r
157 <br>\r
158 &gt; over ssh. Spawning new ssh for every saved search to get the count of<=\r
159 br>\r
160 &gt; matched messages has a way too big overhead. Is this the use case you<=\r
161 br>\r
162 &gt; had in mind when implementing this?<br>\r
163 <br>\r
164 </div>Great to see that you find it useful. Yes, the remote usage was in my=\r
165 <br>\r
166 mind, but it should enhance the local usage as well. We could also<br>\r
167 create a quicker test run using the shell.<br>\r
168 <br>\r
169 The disadvantage of using an interactive shell is that you can have<br>\r
170 only one operation running in the UI, and I see no way of<br>\r
171 interrumpting an operation unless you kill the process, but as<br>\r
172 starting a new shell shouldn&#39;t be a biggie, this might not be as<br>\r
173 limiting as might seem.<br>\r
174 <br>\r
175 The ideal would be for libnotmuch to be able to connect to a<br>\r
176 xapian-tcpsrv, but haven&#39;t had time to look at than, and an<br>\r
177 interactive shell seemed to be less time demanding to implement (and<br>\r
178 had the subjective promise of providing a lot of fun).<br>\r
179 <div class=3D"im"><br>\r
180 &gt; Currently, I have only one comment to the patch. For me, &quot;repl&qu=\r
181 ot; is a bit<br>\r
182 &gt; unintuitive. I was thinking about &quot;shell&quot; as the name of sub=\r
183 command for<br>\r
184 &gt; this.<br>\r
185 <br>\r
186 </div>I agree, maybe &quot;shell&quot; or &quot;interactive&quot; would be =\r
187 more intuitive, but<br>\r
188 when I started &quot;repl&quot; was the only one I could think of.<br>\r
189 <font color=3D"#888888"><br>\r
190 Servilio<br>\r
191 </font><div><div></div><div class=3D"h5">__________________________________=\r
192 _____________<br>\r
193 notmuch mailing list<br>\r
194 <a href=3D"mailto:notmuch@notmuchmail.org">notmuch@notmuchmail.org</a><br>\r
195 <a href=3D"http://notmuchmail.org/mailman/listinfo/notmuch" target=3D"_blan=\r
196 k">http://notmuchmail.org/mailman/listinfo/notmuch</a><br>\r
197 </div></div></blockquote></div><br></div>\r
198 \r
199 --0016362842dee68c950495939126--\r