Re: [PATCH v2] Omit User-Agent: header by default
[notmuch-archives.git] / bb / 04d92de3dabdf193c617ffaa211d1486a302db
1 Return-Path: <jani@nikula.org>\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 3DAF6431FAF\r
6         for <notmuch@notmuchmail.org>; Fri, 30 Nov 2012 11:06:21 -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: -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 pVuXvy4b7LGJ for <notmuch@notmuchmail.org>;\r
16         Fri, 30 Nov 2012 11:06:17 -0800 (PST)\r
17 Received: from mail-la0-f53.google.com (mail-la0-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 92602431FAE\r
21         for <notmuch@notmuchmail.org>; Fri, 30 Nov 2012 11:06:16 -0800 (PST)\r
22 Received: by mail-la0-f53.google.com with SMTP id w12so671033lag.26\r
23         for <notmuch@notmuchmail.org>; Fri, 30 Nov 2012 11:06:15 -0800 (PST)\r
24 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;\r
25         d=google.com; s=20120113;\r
26         h=from:to:subject:in-reply-to:references:user-agent:date:message-id\r
27         :mime-version:content-type:x-gm-message-state;\r
28         bh=t5FzzORnmfTlOnmQEQK+dP9922JCCwH7QY7cA6bQ2Wo=;\r
29         b=XadchziVujplO5ykyu2ic38dHxYzqXorEAsMmFZ3k5CBxP00MwxgpO5+Uj7RIsJhYy\r
30         8D2HHR0TfAcOEJpMUJmULPCs6ZBc2JMvqqBPsQ0Ng/9kUwKhfSNUV3OAIDE5Sowiba3Y\r
31         FzbnE1QB5DHGP1kKrFHgAgznDgR3ud4ny/KUJr7l1R7Dpe6gs5TSucKKiPrPzgEgVlvi\r
32         6gG5MUKOvDc62aSznrJmHTWxEo+W6Z5cEZDKqMUFrwuFvcPYcck/V2YAfQj9C1CjhEGv\r
33         UdTtm1wjS+KY90d2D+9A1gcCgZkErSYVNGk9jc0WmJ2daWEfM0NM8BsYp5Znjv8FQudd\r
34         FW6Q==\r
35 Received: by 10.152.147.100 with SMTP id tj4mr2195859lab.42.1354302375001;\r
36         Fri, 30 Nov 2012 11:06:15 -0800 (PST)\r
37 Received: from localhost (dsl-hkibrasgw4-fe51df00-27.dhcp.inet.fi.\r
38         [80.223.81.27])\r
39         by mx.google.com with ESMTPS id fb1sm2398289lbb.15.2012.11.30.11.06.12\r
40         (version=SSLv3 cipher=OTHER); Fri, 30 Nov 2012 11:06:13 -0800 (PST)\r
41 From: Jani Nikula <jani@nikula.org>\r
42 To: Peter Feigl <craven@gmx.net>, notmuch@notmuchmail.org\r
43 Subject: Re: [PATCH 3/3] Use the S-Expression structured printer in notmuch\r
44         show and notmuch reply.\r
45 In-Reply-To: <1354264143-30173-3-git-send-email-craven@gmx.net>\r
46 References: <1354264143-30173-1-git-send-email-craven@gmx.net>\r
47         <1354264143-30173-3-git-send-email-craven@gmx.net>\r
48 User-Agent: Notmuch/0.14+124~g3b17402 (http://notmuchmail.org) Emacs/23.4.1\r
49         (i686-pc-linux-gnu)\r
50 Date: Fri, 30 Nov 2012 21:06:11 +0200\r
51 Message-ID: <8738zqkj18.fsf@nikula.org>\r
52 MIME-Version: 1.0\r
53 Content-Type: text/plain; charset=us-ascii\r
54 X-Gm-Message-State:\r
55  ALoCoQmfBfFT4UdLmO4s7CNUCm9tKAt59OMienZ5fvN4URTQlXzxayTVvNLdQ/gTKa5ZwXCOspwr\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: Fri, 30 Nov 2012 19:06:21 -0000\r
69 \r
70 On Fri, 30 Nov 2012, Peter Feigl <craven@gmx.net> wrote:\r
71 > This commit changes the json printer (which doesn't do anything\r
72 > json-specific anyway but just uses the structured printers) to generic\r
73 > sprinters, and adds support for the printer defined in sprinter-sexp.c.\r
74 \r
75 I think this patch should be split in two or three: First a\r
76 non-functional preparatory patch that does all the renaming and moves\r
77 sprinter creation up and passes it as parameter. Second the functional\r
78 patch(es) that add sexp support to reply and show.\r
79 \r
80 Please find some other comments below.\r
81 \r
82 BR,\r
83 Jani.\r
84 \r
85 > ---\r
86 >  notmuch-client.h |  8 ++++----\r
87 >  notmuch-reply.c  | 40 ++++++++++++++++++++++++----------------\r
88 >  notmuch-show.c   | 48 +++++++++++++++++++++++++++++-------------------\r
89 >  3 files changed, 57 insertions(+), 39 deletions(-)\r
90 >\r
91 > diff --git a/notmuch-client.h b/notmuch-client.h\r
92 > index ae9344b..1c336dc 100644\r
93 > --- a/notmuch-client.h\r
94 > +++ b/notmuch-client.h\r
95 > @@ -175,12 +175,12 @@ notmuch_status_t\r
96 >  show_one_part (const char *filename, int part);\r
97 >  \r
98 >  void\r
99 > -format_part_json (const void *ctx, struct sprinter *sp, mime_node_t *node,\r
100 > -               notmuch_bool_t first, notmuch_bool_t output_body);\r
101 > +format_part_sprinter (const void *ctx, struct sprinter *sp, mime_node_t *node,\r
102 > +                   notmuch_bool_t first, notmuch_bool_t output_body);\r
103 >  \r
104 >  void\r
105 > -format_headers_json (struct sprinter *sp, GMimeMessage *message,\r
106 > -                  notmuch_bool_t reply);\r
107 > +format_headers_sprinter (struct sprinter *sp, GMimeMessage *message,\r
108 > +                      notmuch_bool_t reply);\r
109 >  \r
110 >  typedef enum {\r
111 >      NOTMUCH_SHOW_TEXT_PART_REPLY = 1 << 0,\r
112 > diff --git a/notmuch-reply.c b/notmuch-reply.c\r
113 > index e60a264..a7469a2 100644\r
114 > --- a/notmuch-reply.c\r
115 > +++ b/notmuch-reply.c\r
116 > @@ -548,7 +548,8 @@ notmuch_reply_format_default(void *ctx,\r
117 >                            notmuch_config_t *config,\r
118 >                            notmuch_query_t *query,\r
119 >                            notmuch_show_params_t *params,\r
120 > -                          notmuch_bool_t reply_all)\r
121 > +                          notmuch_bool_t reply_all,\r
122 > +                          unused (sprinter_t *sp))\r
123 >  {\r
124 >      GMimeMessage *reply;\r
125 >      notmuch_messages_t *messages;\r
126 > @@ -587,17 +588,17 @@ notmuch_reply_format_default(void *ctx,\r
127 >  }\r
128 >  \r
129 >  static int\r
130 > -notmuch_reply_format_json(void *ctx,\r
131 > -                       notmuch_config_t *config,\r
132 > -                       notmuch_query_t *query,\r
133 > -                       notmuch_show_params_t *params,\r
134 > -                       notmuch_bool_t reply_all)\r
135 > +notmuch_reply_format_sprinter(void *ctx,\r
136 > +                           notmuch_config_t *config,\r
137 > +                           notmuch_query_t *query,\r
138 > +                           notmuch_show_params_t *params,\r
139 > +                           notmuch_bool_t reply_all,\r
140 > +                           sprinter_t *sp)\r
141 >  {\r
142 >      GMimeMessage *reply;\r
143 >      notmuch_messages_t *messages;\r
144 >      notmuch_message_t *message;\r
145 >      mime_node_t *node;\r
146 > -    sprinter_t *sp;\r
147 >  \r
148 >      if (notmuch_query_count_messages (query) != 1) {\r
149 >       fprintf (stderr, "Error: search term did not match precisely one message.\n");\r
150 > @@ -613,18 +614,17 @@ notmuch_reply_format_json(void *ctx,\r
151 >      if (!reply)\r
152 >       return 1;\r
153 >  \r
154 > -    sp = sprinter_json_create (ctx, stdout);\r
155 >      sp->begin_map (sp);\r
156 >  \r
157 >      /* The headers of the reply message we've created */\r
158 >      sp->map_key (sp, "reply-headers");\r
159 > -    format_headers_json (sp, reply, TRUE);\r
160 > +    format_headers_sprinter (sp, reply, TRUE);\r
161 >      g_object_unref (G_OBJECT (reply));\r
162 >      reply = NULL;\r
163 >  \r
164 >      /* Start the original */\r
165 >      sp->map_key (sp, "original");\r
166 > -    format_part_json (ctx, sp, node, TRUE, TRUE);\r
167 > +    format_part_sprinter (ctx, sp, node, TRUE, TRUE);\r
168 >  \r
169 >      /* End */\r
170 >      sp->end (sp);\r
171 > @@ -639,7 +639,8 @@ notmuch_reply_format_headers_only(void *ctx,\r
172 >                                 notmuch_config_t *config,\r
173 >                                 notmuch_query_t *query,\r
174 >                                 unused (notmuch_show_params_t *params),\r
175 > -                               notmuch_bool_t reply_all)\r
176 > +                               notmuch_bool_t reply_all,\r
177 > +                               unused (sprinter_t *sp))\r
178 >  {\r
179 >      GMimeMessage *reply;\r
180 >      notmuch_messages_t *messages;\r
181 > @@ -696,6 +697,7 @@ notmuch_reply_format_headers_only(void *ctx,\r
182 >  enum {\r
183 >      FORMAT_DEFAULT,\r
184 >      FORMAT_JSON,\r
185 > +    FORMAT_SEXP,\r
186 >      FORMAT_HEADERS_ONLY,\r
187 >  };\r
188 >  \r
189 > @@ -707,7 +709,7 @@ notmuch_reply_command (void *ctx, int argc, char *argv[])\r
190 >      notmuch_query_t *query;\r
191 >      char *query_string;\r
192 >      int opt_index, ret = 0;\r
193 > -    int (*reply_format_func)(void *ctx, notmuch_config_t *config, notmuch_query_t *query, notmuch_show_params_t *params, notmuch_bool_t reply_all);\r
194 > +    int (*reply_format_func)(void *ctx, notmuch_config_t *config, notmuch_query_t *query, notmuch_show_params_t *params, notmuch_bool_t reply_all, struct sprinter *sp);\r
195 >      notmuch_show_params_t params = {\r
196 >       .part = -1,\r
197 >       .crypto = {\r
198 > @@ -717,11 +719,13 @@ notmuch_reply_command (void *ctx, int argc, char *argv[])\r
199 >      };\r
200 >      int format = FORMAT_DEFAULT;\r
201 >      int reply_all = TRUE;\r
202 > +    struct sprinter *sp = NULL;\r
203 >  \r
204 >      notmuch_opt_desc_t options[] = {\r
205 >       { NOTMUCH_OPT_KEYWORD, &format, "format", 'f',\r
206 >         (notmuch_keyword_t []){ { "default", FORMAT_DEFAULT },\r
207 >                                 { "json", FORMAT_JSON },\r
208 > +                               { "sexp", FORMAT_SEXP },\r
209 >                                 { "headers-only", FORMAT_HEADERS_ONLY },\r
210 >                                 { 0, 0 } } },\r
211 >       { NOTMUCH_OPT_KEYWORD, &reply_all, "reply-to", 'r',\r
212 > @@ -740,9 +744,13 @@ notmuch_reply_command (void *ctx, int argc, char *argv[])\r
213 >  \r
214 >      if (format == FORMAT_HEADERS_ONLY)\r
215 >       reply_format_func = notmuch_reply_format_headers_only;\r
216 > -    else if (format == FORMAT_JSON)\r
217 > -     reply_format_func = notmuch_reply_format_json;\r
218 > -    else\r
219 > +    else if (format == FORMAT_JSON) {\r
220 > +     reply_format_func = notmuch_reply_format_sprinter;\r
221 > +     sp = sprinter_json_create(ctx, stdout);\r
222 \r
223 Space before (.\r
224 \r
225 > +    } else if (format == FORMAT_SEXP) {\r
226 > +     reply_format_func = notmuch_reply_format_sprinter;\r
227 > +     sp = sprinter_sexp_create(ctx, stdout);\r
228 \r
229 Ditto.\r
230 \r
231 > +    } else\r
232 >       reply_format_func = notmuch_reply_format_default;\r
233 \r
234 Please add braces to all branches if you add them to some.\r
235 \r
236 >  \r
237 >      config = notmuch_config_open (ctx, NULL, NULL);\r
238 > @@ -770,7 +778,7 @@ notmuch_reply_command (void *ctx, int argc, char *argv[])\r
239 >       return 1;\r
240 >      }\r
241 >  \r
242 > -    if (reply_format_func (ctx, config, query, &params, reply_all) != 0)\r
243 > +    if (reply_format_func (ctx, config, query, &params, reply_all, sp) != 0)\r
244 >       return 1;\r
245 >  \r
246 >      notmuch_crypto_cleanup (&params.crypto);\r
247 > diff --git a/notmuch-show.c b/notmuch-show.c\r
248 > index 2fa2292..e6da2ff 100644\r
249 > --- a/notmuch-show.c\r
250 > +++ b/notmuch-show.c\r
251 > @@ -32,12 +32,17 @@ static const notmuch_show_format_t format_text = {\r
252 >  };\r
253 >  \r
254 >  static notmuch_status_t\r
255 > -format_part_json_entry (const void *ctx, sprinter_t *sp, mime_node_t *node,\r
256 > +format_part_sprinter_entry (const void *ctx, sprinter_t *sp, mime_node_t *node,\r
257 >                       int indent, const notmuch_show_params_t *params);\r
258 >  \r
259 >  static const notmuch_show_format_t format_json = {\r
260 >      .new_sprinter = sprinter_json_create,\r
261 > -    .part = format_part_json_entry,\r
262 > +    .part = format_part_sprinter_entry,\r
263 > +};\r
264 > +\r
265 > +static const notmuch_show_format_t format_sexp = {\r
266 > +    .new_sprinter = sprinter_sexp_create,\r
267 > +    .part = format_part_sprinter_entry,\r
268 >  };\r
269 >  \r
270 >  static notmuch_status_t\r
271 > @@ -108,9 +113,9 @@ _get_one_line_summary (const void *ctx, notmuch_message_t *message)\r
272 >  /* Emit a sequence of key/value pairs for the metadata of message.\r
273 >   * The caller should begin a map before calling this. */\r
274 >  static void\r
275 > -format_message_json (sprinter_t *sp, notmuch_message_t *message)\r
276 > +format_message_sprinter (sprinter_t *sp, notmuch_message_t *message)\r
277 >  {\r
278 > -    /* Any changes to the JSON format should be reflected in the file\r
279 > +    /* Any changes to the JSON or S-Expression format should be reflected in the file\r
280 >       * devel/schemata. */\r
281 \r
282 You should probably add sexp format description to devel/schemata.\r
283 \r
284 >  \r
285 >      void *local = talloc_new (NULL);\r
286 > @@ -208,7 +213,7 @@ _is_from_line (const char *line)\r
287 >  }\r
288 >  \r
289 >  void\r
290 > -format_headers_json (sprinter_t *sp, GMimeMessage *message,\r
291 > +format_headers_sprinter (sprinter_t *sp, GMimeMessage *message,\r
292 >                    notmuch_bool_t reply)\r
293 >  {\r
294 >      /* Any changes to the JSON format should be reflected in the file\r
295 > @@ -363,7 +368,7 @@ signer_status_to_string (GMimeSignerStatus x)\r
296 >  \r
297 >  #ifdef GMIME_ATLEAST_26\r
298 >  static void\r
299 > -format_part_sigstatus_json (sprinter_t *sp, mime_node_t *node)\r
300 > +format_part_sigstatus_sprinter (sprinter_t *sp, mime_node_t *node)\r
301 >  {\r
302 >      /* Any changes to the JSON format should be reflected in the file\r
303 >       * devel/schemata. */\r
304 > @@ -438,7 +443,7 @@ format_part_sigstatus_json (sprinter_t *sp, mime_node_t *node)\r
305 >  }\r
306 >  #else\r
307 >  static void\r
308 > -format_part_sigstatus_json (sprinter_t *sp, mime_node_t *node)\r
309 > +format_part_sigstatus_sprinter (sprinter_t *sp, mime_node_t *node)\r
310 >  {\r
311 >      const GMimeSignatureValidity* validity = node->sig_validity;\r
312 >  \r
313 > @@ -595,7 +600,7 @@ format_part_text (const void *ctx, sprinter_t *sp, mime_node_t *node,\r
314 >  }\r
315 >  \r
316 >  void\r
317 > -format_part_json (const void *ctx, sprinter_t *sp, mime_node_t *node,\r
318 > +format_part_sprinter (const void *ctx, sprinter_t *sp, mime_node_t *node,\r
319 >                 notmuch_bool_t first, notmuch_bool_t output_body)\r
320 >  {\r
321 >      /* Any changes to the JSON format should be reflected in the file\r
322 > @@ -603,15 +608,15 @@ format_part_json (const void *ctx, sprinter_t *sp, mime_node_t *node,\r
323 >  \r
324 >      if (node->envelope_file) {\r
325 >       sp->begin_map (sp);\r
326 > -     format_message_json (sp, node->envelope_file);\r
327 > +     format_message_sprinter (sp, node->envelope_file);\r
328 >  \r
329 >       sp->map_key (sp, "headers");\r
330 > -     format_headers_json (sp, GMIME_MESSAGE (node->part), FALSE);\r
331 > +     format_headers_sprinter (sp, GMIME_MESSAGE (node->part), FALSE);\r
332 >  \r
333 >       if (output_body) {\r
334 >           sp->map_key (sp, "body");\r
335 >           sp->begin_list (sp);\r
336 > -         format_part_json (ctx, sp, mime_node_child (node, 0), first, TRUE);\r
337 > +         format_part_sprinter (ctx, sp, mime_node_child (node, 0), first, TRUE);\r
338 >           sp->end (sp);\r
339 >       }\r
340 >       sp->end (sp);\r
341 > @@ -646,7 +651,7 @@ format_part_json (const void *ctx, sprinter_t *sp, mime_node_t *node,\r
342 >  \r
343 >      if (node->verify_attempted) {\r
344 >       sp->map_key (sp, "sigstatus");\r
345 > -     format_part_sigstatus_json (sp, node);\r
346 > +     format_part_sigstatus_sprinter (sp, node);\r
347 >      }\r
348 >  \r
349 >      sp->map_key (sp, "content-type");\r
350 > @@ -698,7 +703,7 @@ format_part_json (const void *ctx, sprinter_t *sp, mime_node_t *node,\r
351 >       sp->begin_map (sp);\r
352 >  \r
353 >       sp->map_key (sp, "headers");\r
354 > -     format_headers_json (sp, GMIME_MESSAGE (node->part), FALSE);\r
355 > +     format_headers_sprinter (sp, GMIME_MESSAGE (node->part), FALSE);\r
356 >  \r
357 >       sp->map_key (sp, "body");\r
358 >       sp->begin_list (sp);\r
359 > @@ -706,7 +711,7 @@ format_part_json (const void *ctx, sprinter_t *sp, mime_node_t *node,\r
360 >      }\r
361 >  \r
362 >      for (i = 0; i < node->nchildren; i++)\r
363 > -     format_part_json (ctx, sp, mime_node_child (node, i), i == 0, TRUE);\r
364 > +     format_part_sprinter (ctx, sp, mime_node_child (node, i), i == 0, TRUE);\r
365 >  \r
366 >      /* Close content structures */\r
367 >      for (i = 0; i < nclose; i++)\r
368 > @@ -716,11 +721,11 @@ format_part_json (const void *ctx, sprinter_t *sp, mime_node_t *node,\r
369 >  }\r
370 >  \r
371 >  static notmuch_status_t\r
372 > -format_part_json_entry (const void *ctx, sprinter_t *sp,\r
373 > +format_part_sprinter_entry (const void *ctx, sprinter_t *sp,\r
374 >                       mime_node_t *node, unused (int indent),\r
375 >                       const notmuch_show_params_t *params)\r
376 >  {\r
377 > -    format_part_json (ctx, sp, node, TRUE, params->output_body);\r
378 > +    format_part_sprinter (ctx, sp, node, TRUE, params->output_body);\r
379 >  \r
380 >      return NOTMUCH_STATUS_SUCCESS;\r
381 >  }\r
382 > @@ -1012,6 +1017,7 @@ do_show (void *ctx,\r
383 >  enum {\r
384 >      NOTMUCH_FORMAT_NOT_SPECIFIED,\r
385 >      NOTMUCH_FORMAT_JSON,\r
386 > +    NOTMUCH_FORMAT_SEXP,\r
387 >      NOTMUCH_FORMAT_TEXT,\r
388 >      NOTMUCH_FORMAT_MBOX,\r
389 >      NOTMUCH_FORMAT_RAW\r
390 > @@ -1056,6 +1062,7 @@ notmuch_show_command (void *ctx, unused (int argc), unused (char *argv[]))\r
391 >       { NOTMUCH_OPT_KEYWORD, &format_sel, "format", 'f',\r
392 >         (notmuch_keyword_t []){ { "json", NOTMUCH_FORMAT_JSON },\r
393 >                                 { "text", NOTMUCH_FORMAT_TEXT },\r
394 > +                               { "sexp", NOTMUCH_FORMAT_SEXP },\r
395 >                                 { "mbox", NOTMUCH_FORMAT_MBOX },\r
396 >                                 { "raw", NOTMUCH_FORMAT_RAW },\r
397 >                                 { 0, 0 } } },\r
398 > @@ -1100,6 +1107,9 @@ notmuch_show_command (void *ctx, unused (int argc), unused (char *argv[]))\r
399 >      case NOTMUCH_FORMAT_TEXT:\r
400 >       format = &format_text;\r
401 >       break;\r
402 > +    case NOTMUCH_FORMAT_SEXP:\r
403 > +     format = &format_sexp;\r
404 > +     break;\r
405 >      case NOTMUCH_FORMAT_MBOX:\r
406 >       if (params.part > 0) {\r
407 >           fprintf (stderr, "Error: specifying parts is incompatible with mbox output format.\n");\r
408 > @@ -1120,7 +1130,7 @@ notmuch_show_command (void *ctx, unused (int argc), unused (char *argv[]))\r
409 >  \r
410 >      /* Default is entire-thread = FALSE except for format=json. */\r
411 >      if (entire_thread == ENTIRE_THREAD_DEFAULT) {\r
412 > -     if (format == &format_json)\r
413 > +     if (format == &format_json || format == &format_sexp)\r
414 >           entire_thread = ENTIRE_THREAD_TRUE;\r
415 >       else\r
416 >           entire_thread = ENTIRE_THREAD_FALSE;\r
417 > @@ -1131,8 +1141,8 @@ notmuch_show_command (void *ctx, unused (int argc), unused (char *argv[]))\r
418 >           fprintf (stderr, "Warning: --body=false is incompatible with --part > 0. Disabling.\n");\r
419 >           params.output_body = TRUE;\r
420 >       } else {\r
421 > -         if (format != &format_json)\r
422 > -             fprintf (stderr, "Warning: --body=false only implemented for format=json\n");\r
423 > +         if (format != &format_json && format != &format_sexp)\r
424 > +             fprintf (stderr, "Warning: --body=false only implemented for format=json or format=sexp\n");\r
425 \r
426 s/or/and/ ?\r
427 \r
428 >       }\r
429 >      }\r
430 >  \r
431 > -- \r
432 > 1.8.0\r
433 >\r
434 > _______________________________________________\r
435 > notmuch mailing list\r
436 > notmuch@notmuchmail.org\r
437 > http://notmuchmail.org/mailman/listinfo/notmuch\r