--- /dev/null
+Return-Path: <bremner@tesseract.cs.unb.ca>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+ by arlo.cworth.org (Postfix) with ESMTP id 639416DE00C9\r
+ for <notmuch@notmuchmail.org>; Wed, 29 Jun 2016 13:34:38 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at cworth.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -0.005\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-0.005 tagged_above=-999 required=5\r
+ tests=[AWL=-0.006, HEADER_FROM_DIFFERENT_DOMAINS=0.001]\r
+ autolearn=disabled\r
+Received: from arlo.cworth.org ([127.0.0.1])\r
+ by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024)\r
+ with ESMTP id dYtzWPiOuhjI for <notmuch@notmuchmail.org>;\r
+ Wed, 29 Jun 2016 13:34:30 -0700 (PDT)\r
+Received: from fethera.tethera.net (fethera.tethera.net [198.245.60.197])\r
+ by arlo.cworth.org (Postfix) with ESMTPS id 99F566DE00BF\r
+ for <notmuch@notmuchmail.org>; Wed, 29 Jun 2016 13:34:30 -0700 (PDT)\r
+Received: from remotemail by fethera.tethera.net with local (Exim 4.84)\r
+ (envelope-from <bremner@tesseract.cs.unb.ca>)\r
+ id 1bIMBV-0007VG-Tx; Wed, 29 Jun 2016 16:34:09 -0400\r
+Received: (nullmailer pid 2609 invoked by uid 1000);\r
+ Wed, 29 Jun 2016 20:34:24 -0000\r
+From: David Bremner <david@tethera.net>\r
+To: notmuch@notmuchmail.org\r
+Subject: [RFC PATCH] cli/search: interpret no search terms as synonym for '*'\r
+Date: Wed, 29 Jun 2016 22:34:06 +0200\r
+Message-Id: <1467232446-2442-1-git-send-email-david@tethera.net>\r
+X-Mailer: git-send-email 2.8.1\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.20\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+ <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <https://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: <https://notmuchmail.org/mailman/listinfo/notmuch>,\r
+ <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Wed, 29 Jun 2016 20:34:38 -0000\r
+\r
+This is a bit less typing (and escaping), especially for the\r
+--output=tags case.\r
+---\r
+\r
+I started merrily on other commands, but I'm not so sure. For example\r
+"git annex metadata" has the feature of interpreting missing file name\r
+as all files and I find it super irritating in general because I keep\r
+adding tags to all files. Hence RFC.\r
+\r
+ notmuch-search.c | 7 ++-----\r
+ 1 file changed, 2 insertions(+), 5 deletions(-)\r
+\r
+diff --git a/notmuch-search.c b/notmuch-search.c\r
+index 8c65d5a..a7e397c 100644\r
+--- a/notmuch-search.c\r
++++ b/notmuch-search.c\r
+@@ -625,7 +625,8 @@ do_search_tags (const search_context_t *ctx)\r
+ * specified? */\r
+ \r
+ /* Special-case query of "*" for better performance. */\r
+- if (strcmp (notmuch_query_get_query_string (query), "*") == 0) {\r
++ if (strcmp (notmuch_query_get_query_string (query), "*") == 0 ||\r
++ strlen (notmuch_query_get_query_string (query)) == 0) {\r
+ tags = notmuch_database_get_all_tags (notmuch);\r
+ } else {\r
+ notmuch_status_t status;\r
+@@ -711,10 +712,6 @@ _notmuch_search_prepare (search_context_t *ctx, notmuch_config_t *config, int ar\r
+ fprintf (stderr, "Out of memory.\n");\r
+ return EXIT_FAILURE;\r
+ }\r
+- if (*query_str == '\0') {\r
+- fprintf (stderr, "Error: notmuch search requires at least one search term.\n");\r
+- return EXIT_FAILURE;\r
+- }\r
+ \r
+ ctx->query = notmuch_query_create (ctx->notmuch, query_str);\r
+ if (ctx->query == NULL) {\r
+-- \r
+2.8.1\r
+\r