From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.user/18906 Path: news.gmane.org!.POSTED!not-for-mail From: Eric Abrahamsen Newsgroups: gmane.emacs.gnus.user Subject: Re: nnir notmuch search on specific groups? Date: Wed, 24 Oct 2018 08:47:49 +0800 Message-ID: <871s8gcgqy.fsf@ericabrahamsen.net> References: <87a7n8s2np.fsf@hfph.mwn.de> <87o9bohsdw.fsf@ericabrahamsen.net> <87k1mbege2.fsf@tullinup.koldfront.dk> <87bm7ni6sy.fsf@ericabrahamsen.net> <87a7n79ojs.fsf@tullinup.koldfront.dk> <878t2rjde8.fsf@hfph.mwn.de> <87va5vhudu.fsf@hfph.mwn.de> <87ftwwe6vs.fsf@hfph.mwn.de> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: blaine.gmane.org 1540342600 19161 195.159.176.226 (24 Oct 2018 00:56:40 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Wed, 24 Oct 2018 00:56:40 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) To: info-gnus-english@gnu.org Original-X-From: info-gnus-english-bounces+gegu-info-gnus-english=m.gmane.org@gnu.org Wed Oct 24 02:56:36 2018 Return-path: Envelope-to: gegu-info-gnus-english@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gF7TP-0004t7-Fj for gegu-info-gnus-english@m.gmane.org; Wed, 24 Oct 2018 02:56:35 +0200 Original-Received: from localhost ([::1]:45015 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gF7VV-0006sE-Fw for gegu-info-gnus-english@m.gmane.org; Tue, 23 Oct 2018 20:58:45 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:60057) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gF7VO-0006Lq-NI for info-gnus-english@gnu.org; Tue, 23 Oct 2018 20:58:43 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gF7L4-0007e2-Nh for info-gnus-english@gnu.org; Tue, 23 Oct 2018 20:48:02 -0400 Original-Received: from [195.159.176.226] (port=58130 helo=blaine.gmane.org) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gF7L4-0007cY-Ef for info-gnus-english@gnu.org; Tue, 23 Oct 2018 20:47:58 -0400 Original-Received: from list by blaine.gmane.org with local (Exim 4.84_2) (envelope-from ) id 1gF7Iv-0001L2-31 for info-gnus-english@gnu.org; Wed, 24 Oct 2018 02:45:45 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 34 Original-X-Complaints-To: usenet@blaine.gmane.org Cancel-Lock: sha1:nAMil8PqVJcyW35D0h/hIp2jYJY= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 195.159.176.226 X-BeenThere: info-gnus-english@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Announcements and discussions for GNUS, the GNU Emacs Usenet newsreader \(in English\)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: info-gnus-english-bounces+gegu-info-gnus-english=m.gmane.org@gnu.org Original-Sender: "info-gnus-english" Xref: news.gmane.org gmane.emacs.gnus.user:18906 Archived-At: "Andreas Goesele" writes: > Eric Abrahamsen writes: > >> Okay, I've reported this with a patch as bug#33122. The new option name >> is called `nnir-notmuch-filter-group-names-function'. >> >> In the end I decided a t value didn't make a lot of sense -- if users >> want to pass the group names through unchanged (which is almost >> certainly a bad idea), they can set the above option to #'identity. >> >> By default (assuming this patch is accepted with no change), the >> filtering *doesn't* do the transform you wanted. You can add your >> desired behavior (the docstring mentions this) like so: >> >> (add-function :filter-return nnir-notmuch-filter-group-names-function >> (lambda (g) (replace-regexp-in-string "\\." "/" g))) > > Thanks, this basically works great. There is just one small glitch: If > one marks different groups (let say three) the search becomes: > > search --format=text --output=files search-term path: or > path: or path: > > This includes all mails in the directories 2 and 3 > > So it should be: > > search --format=text --output=files search-term (path: or > path: or path:) Aha! Thanks for the pointer. I've updated the patch on the bug report. Eric