Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id C3EDC431FBC for ; Wed, 24 Feb 2010 06:27:32 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -0.389 X-Spam-Level: X-Spam-Status: No, score=-0.389 tagged_above=-999 required=5 tests=[AWL=-0.390, BAYES_50=0.001] autolearn=ham Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id DH4o4QvgULH1 for ; Wed, 24 Feb 2010 06:27:31 -0800 (PST) Received: from smtp5-g21.free.fr (smtp5-g21.free.fr [212.27.42.5]) by olra.theworths.org (Postfix) with ESMTP id B8A79431FAE for ; Wed, 24 Feb 2010 06:27:30 -0800 (PST) Received: from smtp5-g21.free.fr (localhost [127.0.0.1]) by smtp5-g21.free.fr (Postfix) with ESMTP id 29336D480AF; Wed, 24 Feb 2010 15:27:21 +0100 (CET) Received: from zimbra1-e1.priv.proxad.net (zimbra1-e1.priv.proxad.net [172.20.243.151]) by smtp5-g21.free.fr (Postfix) with ESMTP id 1F905D4819D; Wed, 24 Feb 2010 15:27:18 +0100 (CET) Date: Wed, 24 Feb 2010 15:27:18 +0100 (CET) From: racin@free.fr To: Sebastian Spaeth Message-ID: <74981806.5014941267021638774.JavaMail.root@zimbra1-e1.priv.proxad.net> In-Reply-To: <1257161639.5014171267021461605.JavaMail.root@zimbra1-e1.priv.proxad.net> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Originating-IP: [132.166.135.72] X-Mailer: Zimbra 5.0 (ZimbraWebClient - FF3.0 (Linux)/5.0.15_GA_2815.UBUNTU8_64) X-Authenticated-User: racin@free.fr Cc: notmuch@notmuchmail.org Subject: Re: [notmuch] JSON output as default [was: Re: [PATCH] Add an "--output=(json|text|)" command-line option...] X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 24 Feb 2010 14:27:32 -0000 > > I definitely want to be able to pipe single-field lists coming from > > notmuch to grep, xargs, shell for loops, etc. without having to > decode > > JSON. > > While I would love to see JSON (even by default), I agree. If I just > want to code up a notmuch-based address book with sth like: > > notmuch show to:Diana --output=to --sort=relevance --limit=20 > > just getting back a plain list of mail addresses is the easiest to > handle. This would also be useful for the Emacs/Vim interfaces. For instance, my smart completion patch would really benefit from notmuch being capable of outputing various fields in all messages in plain text separated by newlines (this is even easier to handle in emacs code than JSON). In fact, most of the C code I had to write for this patch is better replaced by the --output option...