From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:403:4ea1::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms12 with LMTPS id iHKAKm81y2F7fgAAsNZ9tg (envelope-from ) for ; Tue, 28 Dec 2021 16:03:59 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id sDd4J281y2GceQAAG6o9tA (envelope-from ) for ; Tue, 28 Dec 2021 17:03:59 +0100 Received: from mail.yoctocell.xyz (h87-96-130-155.cust.a3fiber.se [87.96.130.155]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 7B89E38702 for ; Tue, 28 Dec 2021 17:03:56 +0100 (CET) From: Xinglu Chen DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yoctocell.xyz; s=mail; t=1640707434; bh=gco90cLQYOnsUR109TG6qPKHbObf7PuOe3oq0chDM0I=; h=From:To:Subject:In-Reply-To:References:Date; b=PZYI9WIkzjfyTlcWipQo6zaRAxNnAUyLFqDXhEjcDJhZYCsVKHNyxCX5pcu0HjyUu ZXOkd0RQWCzgacSq1luxysZ2LDYCgCocXIfPpnCHezpdoNJP2p97K8FAdLAFtVYSu2 UGH7tQsnz9NUi3Rh956nga4Z0YqAENwNJaClmy54= To: Kyle Meyer , piem@inbox.kyleam.com Subject: Re: [PATCH 3/6] lei q: Support displaying multiple threads In-Reply-To: <20211228022037.206597-4-kyle@kyleam.com> References: <20211228022037.206597-1-kyle@kyleam.com> <20211228022037.206597-4-kyle@kyleam.com> Date: Tue, 28 Dec 2021 17:03:52 +0100 Message-ID: <87wnjosolz.fsf@yoctocell.xyz> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" Authentication-Results: aspmx1.migadu.com; none X-Migadu-Scanner: scn0.migadu.com X-TUID: 04kPp8HKV6vJ --=-=-= Content-Type: text/plain Kyle schrieb am Montag der 27. Dezember 2021 um 21:20 -05: > piem-lei-query shows unthreaded results. From there, > piem-lei-query-thread can be used to show the entire thread for that > result. This design is driven largely by my use of Notmuch, where I > call notmuch-search and then follow up with a custom variant of > notmuch-tree to show _one_ thread. > > However, users familiar with notmuch-tree probably expect to be able > to display _multiple_ threads. piem-lei-query--thread already returns > a list of threads, so it really just needs to be exposed at the > command level. > > Update piem-lei-query-thread to make it handle a general query, > renaming it slightly to make it clearer that the command now supports > displaying multiple threads. Then, add a wrapper piem-lei-mid-thread > that handles the old "single thread for a given MID" behavior. > > Rather than adding another suffix command to the lei-q transient > (piem-lei-query-threads in addition to the existing piem-lei-query), I > considered adding --threads to the transient and then having > piem-lei-query check whether it's in the arguments. Conceptually, I > dislike that because it conflates threaded _display_ with lei's > --threads behavior that's instead about whether to include other > messages from a match's thread in the results. Also, it'd mean some > downstream handling of piem-lei-buffer-args (e.g., by > piem-lei-query-show) would be complicated by the need to filter out > --threads. > > Note that piem-lei-query-thread no longer sets piem-lei-buffer-mid > because the buffer is no longer tied to a single message ID, which is > okay because, unlike in show buffers, the value isn't actually used. > > Suggested-by: Xinglu Chen > Link: https://inbox.kyleam.com/piem/871r96am1q.fsf@yoctocell.xyz > --- > piem-lei.el | 41 +++++++++++++++++++++++++++-------------- > 1 file changed, 27 insertions(+), 14 deletions(-) The changes look good to me, and things work as expected. Thanks for the work! --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQJJBAEBCAAzFiEEAVhh4yyK5+SEykIzrPUJmaL7XHkFAmHLNWkVHHB1YmxpY0B5 b2N0b2NlbGwueHl6AAoJEKz1CZmi+1x5QKIQAK8GGrROtbO5T1cwox8nQRZk+H9E Hw7SxjCsS+SnZO05HIqLnMpbvxzHbBwu3qXX3D0K8NL0v8hzLMCl8zWYF2HZjzpT ub6RiRG8TzrDiuNPXNewdgHvGtAwFPUuamtNZsHILgmFXZAWL4o93fwq7b4//lxj gsR+QIX1/B8jOY2IjFPLiHZYiq4JFG+BV71lzMX0k/p39fCatflnNAbZeXcYIFON 9WgtzD5m7DKx139SZwlvOZrT+aydTtW6B4k68wZaBpXV6EJu7jWs+CU41TfJvy+S /0viErECeuxE8ZMbsLit+iEfyOAfxpO7b0eQECpMfGB7f6+aBe9+8yMrKX2g0UTv +XC9BZe9v7vIy2tk04NsSY3yF9EIDdHXI7lwrEKijvhxbfQatMQiJfTMVklIOXao ZbyYAyLgJ8GLvCJlr0A3CgJf0BMdojvmSU74FfoC5Ffwax+doOIYQGiGisv9NYPs ke464GWRVFBRZMckJ3A8cq9oiIagnctMnWFrK+1jxSVS+bpDYdTJlpxZLMIRkyd0 +I+hua/X4p4EWG1b9fBEtSQIAxsnxrsfGrSYZ+TQKme+AUrI06mutmzcIQebJT87 fKS7Nt6YLi3h+vITSzz6mbmsAiRFpZKWCFtRSCTxu1eyXEw7NJIgEpYzflM7c8IQ NqkhzKYSoJHuY0rf =aSk+ -----END PGP SIGNATURE----- --=-=-=--