--- /dev/null
+Return-Path: <sojkam1@fel.cvut.cz>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+ by olra.theworths.org (Postfix) with ESMTP id E923A431FAE\r
+ for <notmuch@notmuchmail.org>; Mon, 22 Sep 2014 02:39:48 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -2.3\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-2.3 tagged_above=-999 required=5\r
+ tests=[RCVD_IN_DNSWL_MED=-2.3] autolearn=disabled\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+ by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+ with ESMTP id yngT4UwdKOQv for <notmuch@notmuchmail.org>;\r
+ Mon, 22 Sep 2014 02:39:42 -0700 (PDT)\r
+Received: from max.feld.cvut.cz (max.feld.cvut.cz [147.32.192.36])\r
+ by olra.theworths.org (Postfix) with ESMTP id 8C50F431FC3\r
+ for <notmuch@notmuchmail.org>; Mon, 22 Sep 2014 02:39:29 -0700 (PDT)\r
+Received: from localhost (unknown [192.168.200.7])\r
+ by max.feld.cvut.cz (Postfix) with ESMTP id 3C5793CFEA9;\r
+ Mon, 22 Sep 2014 11:39:26 +0200 (CEST)\r
+X-Virus-Scanned: IMAP STYX AMAVIS\r
+Received: from max.feld.cvut.cz ([192.168.200.1])\r
+ by localhost (styx.feld.cvut.cz [192.168.200.7]) (amavisd-new,\r
+ port 10044)\r
+ with ESMTP id 4FBJj1k1da1M; Mon, 22 Sep 2014 11:39:22 +0200 (CEST)\r
+Received: from imap.feld.cvut.cz (imap.feld.cvut.cz [147.32.192.34])\r
+ by max.feld.cvut.cz (Postfix) with ESMTP id 6A7B05CCE62;\r
+ Mon, 22 Sep 2014 11:39:22 +0200 (CEST)\r
+Received: from wsh by steelpick.2x.cz with local (Exim 4.84)\r
+ (envelope-from <sojkam1@fel.cvut.cz>)\r
+ id 1XW05U-0001w0-Il; Mon, 22 Sep 2014 11:39:16 +0200\r
+From: Michal Sojka <sojkam1@fel.cvut.cz>\r
+To: notmuch@notmuchmail.org\r
+Subject: [PATCH 0/5] notmuch search --output=addresses\r
+Date: Mon, 22 Sep 2014 11:37:54 +0200\r
+Message-Id: <1411378679-7307-1-git-send-email-sojkam1@fel.cvut.cz>\r
+X-Mailer: git-send-email 2.1.0\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+ <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+ <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+ <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Mon, 22 Sep 2014 09:39:49 -0000\r
+\r
+Hello all,\r
+\r
+this patch series adds support for --output=addresses and similar\r
+arguments in notmuch search. It is a reworked and extended version of\r
+id:1410021689-15901-1-git-send-email-jani@nikula.org.\r
+\r
+Compared to Jani's patches, I do not use keyword-flag command line\r
+parser for the --output option, because this would not be useful for\r
+most but one combination of keywords. Instead, this one combination is\r
+explicitely mentioned as another keyword.\r
+\r
+The flag command-line parser is introduced later, with (IMHO) better\r
+syntax: --flags=one,two,... This feature is used to control address\r
+deduplication via the --unique option.\r
+\r
+Other extensions are added documentation, tests and shell completions.\r
+\r
+The whole test suite passes with these patches.\r
+\r
+The functionality presented here will be useful for improving Emacs\r
+address completion (id:1411150602-21892-1-git-send-email-sojkam1@fel.cvut.cz).\r
+\r
+Another nice use case is sending patched with git:\r
+\r
+ git send-email --cc-cmd='nmsenders id:xxxx' ...\r
+\r
+where nmsenders script contains:\r
+\r
+ notmuch search --output=sender $(notmuch search --output=threads $1)\r
+\r
+\r
+\r
+Michal Sojka (5):\r
+ cli: Refactor option passing in the search command\r
+ cli: Extend the search command for --output=addresses and similar\r
+ cli: Add support for parsing command line "flag" options\r
+ cli: Add configurable address deduplication for --output=addresses\r
+ cli: Add tests for 'search --output=addresses' and similar\r
+\r
+ command-line-arguments.c | 40 +++++\r
+ command-line-arguments.h | 1 +\r
+ completion/notmuch-completion.bash | 8 +-\r
+ completion/notmuch-completion.zsh | 4 +-\r
+ doc/man1/notmuch-search.rst | 55 ++++++-\r
+ notmuch-search.c | 311 +++++++++++++++++++++++++++++--------\r
+ test/Makefile.local | 2 +-\r
+ test/T090-search-output.sh | 59 +++++++\r
+ test/T095-search-unique.sh | 63 ++++++++\r
+ test/T410-argument-parsing.sh | 3 +-\r
+ test/arg-test.c | 8 +\r
+ 11 files changed, 482 insertions(+), 72 deletions(-)\r
+ create mode 100755 test/T095-search-unique.sh\r
+\r
+-- \r
+2.1.0\r
+\r