[PATCH v2 11/14] cli/reply: return internet address list from get header funcs
[notmuch-archives.git] / 43 / 283135860ad35ec9c1d995e64304ee192508bd
1 Return-Path: <bremner@unb.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 73DD2431FD0\r
6         for <notmuch@notmuchmail.org>; Wed, 30 Nov 2011 17:15:54 -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.3\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=-2.3 tagged_above=-999 required=5\r
12         tests=[RCVD_IN_DNSWL_MED=-2.3] 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 gv0j4kw8Fj6a for <notmuch@notmuchmail.org>;\r
16         Wed, 30 Nov 2011 17:15:53 -0800 (PST)\r
17 Received: from tempo.its.unb.ca (tempo.its.unb.ca [131.202.1.21])\r
18         (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits))\r
19         (No client certificate requested)\r
20         by olra.theworths.org (Postfix) with ESMTPS id AA8DB429E21\r
21         for <notmuch@notmuchmail.org>; Wed, 30 Nov 2011 17:15:53 -0800 (PST)\r
22 Received: from rocinante.cs.unb.ca (m3.kereda.com [207.194.238.3] (may be\r
23         forged)) (authenticated bits=0)\r
24         by tempo.its.unb.ca (8.13.8/8.13.8) with ESMTP id pB11FnvS008710\r
25         (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NO);\r
26         Wed, 30 Nov 2011 21:15:50 -0400\r
27 Received: from bremner by rocinante.cs.unb.ca with local (Exim 4.76)\r
28         (envelope-from <bremner@tesseract.cs.unb.ca>)\r
29         id 1RVvFd-0006qW-B1; Wed, 30 Nov 2011 17:15:49 -0800\r
30 From: David Bremner <bremner@debian.org>\r
31 To: notmuch@notmuchmail.org\r
32 Subject: [PATCH 3/3] notmuch-dump.c: add a format option\r
33 Date: Wed, 30 Nov 2011 17:15:30 -0800\r
34 Message-Id: <1322702130-26068-3-git-send-email-bremner@debian.org>\r
35 X-Mailer: git-send-email 1.7.5.4\r
36 In-Reply-To: <1322702130-26068-1-git-send-email-bremner@debian.org>\r
37 References:\r
38  <7574621578db9bbfc88348c87e2f5431f4cb2296.1321223343.git.jani@nikula.org>\r
39         <1322702130-26068-1-git-send-email-bremner@debian.org>\r
40 Cc: David Bremner <bremner@debian.org>\r
41 X-BeenThere: notmuch@notmuchmail.org\r
42 X-Mailman-Version: 2.1.13\r
43 Precedence: list\r
44 List-Id: "Use and development of the notmuch mail system."\r
45         <notmuch.notmuchmail.org>\r
46 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
47         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
48 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
49 List-Post: <mailto:notmuch@notmuchmail.org>\r
50 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
51 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
52         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
53 X-List-Received-Date: Thu, 01 Dec 2011 01:15:54 -0000\r
54 \r
55 Note that the option does not do anything yet.\r
56 ---\r
57  notmuch-dump.c |    6 ++++++\r
58  1 files changed, 6 insertions(+), 0 deletions(-)\r
59 \r
60 diff --git a/notmuch-dump.c b/notmuch-dump.c\r
61 index 8a8d6ec..2a6daef 100644\r
62 --- a/notmuch-dump.c\r
63 +++ b/notmuch-dump.c\r
64 @@ -43,10 +43,13 @@ notmuch_dump_command (unused (void *ctx), int argc, char *argv[])\r
65         return 1;\r
66  \r
67      notmuch_opt_desc_t options[] = {\r
68 +       { "format", 'f', NOTMUCH_OPT_KEYWORD,\r
69 +         (notmuch_keyword_t []){ { "sup", 's' }, { "path", 'p' }, {0, 0} } },\r
70         { 0, 0, 0, 0 }\r
71      };\r
72  \r
73      notmuch_opt_t result;\r
74 +    int output_format='s';\r
75      int opt_index;\r
76      notmuch_bool_t more_args=TRUE;\r
77  \r
78 @@ -55,6 +58,9 @@ notmuch_dump_command (unused (void *ctx), int argc, char *argv[])\r
79         more_args=parse_argument (argv[0], argv[opt_index], options, &result);\r
80  \r
81         switch (result.arg_id) {\r
82 +       case 'f':\r
83 +           output_format=result.keyword_id;\r
84 +           break;\r
85         case '?':\r
86             return 1;\r
87             break;\r
88 -- \r
89 1.7.5.4\r
90 \r