Re: [notmuch] [PATCH 2/3] have _notmuch_thread_create mark which messages matched...
authorCarl Worth <cworth@cworth.org>
Sat, 28 Nov 2009 01:15:35 +0000 (17:15 +1600)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:35:45 +0000 (09:35 -0800)
ad/1580df080bf60e44f54ce0c25ea9d9ad105928 [new file with mode: 0644]

diff --git a/ad/1580df080bf60e44f54ce0c25ea9d9ad105928 b/ad/1580df080bf60e44f54ce0c25ea9d9ad105928
new file mode 100644 (file)
index 0000000..8a5517a
--- /dev/null
@@ -0,0 +1,86 @@
+Return-Path: <cworth@cworth.org>\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 2090E431FC0;\r
+       Fri, 27 Nov 2009 17:15:51 -0800 (PST)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\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 cPgnj0zDe6s8; Fri, 27 Nov 2009 17:15:50 -0800 (PST)\r
+Received: from cworth.org (localhost [127.0.0.1])\r
+       by olra.theworths.org (Postfix) with ESMTP id 429B7431FAE;\r
+       Fri, 27 Nov 2009 17:15:50 -0800 (PST)\r
+From: Carl Worth <cworth@cworth.org>\r
+To: Bart Trojanowski <bart@jukie.net>, notmuch@notmuchmail.org\r
+In-Reply-To: <1259124875-28212-3-git-send-email-bart@jukie.net>\r
+References: <1259124875-28212-1-git-send-email-bart@jukie.net>\r
+       <1259124875-28212-2-git-send-email-bart@jukie.net>\r
+       <1259124875-28212-3-git-send-email-bart@jukie.net>\r
+Date: Fri, 27 Nov 2009 17:15:35 -0800\r
+Message-ID: <87iqcvbgaw.fsf@yoom.home.cworth.org>\r
+MIME-Version: 1.0\r
+Content-Type: text/plain; charset=us-ascii\r
+Cc: Bart Trojanowski <bart@jukie.net>\r
+Subject: Re: [notmuch] [PATCH 2/3] have _notmuch_thread_create mark which\r
+ messages matched the query\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.12\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: Sat, 28 Nov 2009 01:15:51 -0000\r
+\r
+On Tue, 24 Nov 2009 23:54:34 -0500, Bart Trojanowski <bart@jukie.net> wrote:\r
+> When _notmuch_thread_create() is given a query string, it can return more\r
+> messages than just those matching the query.  To distinguish those that\r
+> matched the query expression, the MATCHING_SEARCH flag is set\r
+> appropriately.\r
+\r
+This is a very useful feature, Bart. Thanks for coding it up. And it's a\r
+nicely-implemented patch series as well.\r
+\r
+I've pushed this out now, so anyone reading along should be able to try\r
+it with:\r
+\r
+./notmuch show thread:6d5e3e276461188c5778c9f219f63782 and subject:"PATCH 2/3"\r
+\r
+I can't wait to have the emacs support for opening only matched messages\r
+by default.\r
+\r
+By the way, do you think that this support obviates the\r
+--only-matching-messages option for "notmuch search" or does anyone\r
+still want that?\r
+\r
+Or maybe the right fix is to make "notmuch show" display only matching\r
+messages by default, (which will likely be more friendly to a user\r
+manually typing "notmuch show" at the command line). And then make the\r
+user-interfaces pass an "--entire-thread" option (or so) to get the\r
+current results.\r
+\r
+If we're going to make the command-line user-interface usable on its\r
+own, then I definitely want to make it be the user interfaces that have\r
+to pass extra-long command-line options to get what they want.\r
+\r
+One quick point on naming:\r
+\r
+>  /* Message flags */\r
+>  typedef enum _notmuch_message_flag {\r
+> +    NOTMUCH_MSG_FLAG_MATCHING_SEARCH,\r
+>  } notmuch_message_flag_t;\r
+\r
+I like my enum values to match their type name without abbreviation. I\r
+also like internals (like this enum value) to match the way they are\r
+exposed in the interface, (which in this case is "match"). So I'd like\r
+the above value to instead be:\r
+\r
+       NOTMUCH_MESSAGE_FLAG_MATCH\r
+\r
+-Carl\r