From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by arlo.cworth.org (Postfix) with ESMTP id 44CAE6DE0F4C for ; Mon, 11 Mar 2019 18:13:28 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at cworth.org X-Spam-Flag: NO X-Spam-Score: -0.007 X-Spam-Level: X-Spam-Status: No, score=-0.007 tagged_above=-999 required=5 tests=[AWL=-0.016, SPF_PASS=-0.001, T_FILL_THIS_FORM_SHORT=0.01] autolearn=disabled Received: from arlo.cworth.org ([127.0.0.1]) by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 6iMhpt33kg_D for ; Mon, 11 Mar 2019 18:13:27 -0700 (PDT) Received: from fethera.tethera.net (fethera.tethera.net [198.245.60.197]) by arlo.cworth.org (Postfix) with ESMTPS id 9D55F6DE104E for ; Mon, 11 Mar 2019 18:13:27 -0700 (PDT) Received: from remotemail by fethera.tethera.net with local (Exim 4.89) (envelope-from ) id 1h3Vyr-0000On-4w; Mon, 11 Mar 2019 21:13:21 -0400 Received: (nullmailer pid 9717 invoked by uid 1000); Tue, 12 Mar 2019 01:13:20 -0000 From: David Bremner To: Matt Armstrong , Carl Worth , Gregor Zattler , notmuch@notmuchmail.org Subject: Re: how to search for hyphenated words? (was: how to search for Morse code?) In-Reply-To: References: <87muui87om.fsf@len.workgroup> <87ef7hyxqs.fsf@len.workgroup> <87a7i4c3t5.fsf@wondoo.home.cworth.org> Date: Mon, 11 Mar 2019 22:13:20 -0300 Message-ID: <87wol4dhe7.fsf@tethera.net> MIME-Version: 1.0 Content-Type: text/plain X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Mar 2019 01:13:28 -0000 Matt Armstrong writes: > Carl Worth writes: > >> Hi Gregor, >> >> The trick here is that when notmuch is indexing body text it feeds it >> into a Xapian function that parses the text by finding "terms" in the >> text. And this parser considers both punctuation and whitespace as >> separators between terms. > > I notice that Xapian supports something called "phrase searches", > documented as: > > "A phrase surrounded with double quotes ("") matches documents > containing that exact phrase. Hyphenated words are also treated as > phrases, as are cases such as filenames and email addresses > (e.g. /etc/passwd or president@whitehouse.gov)." > > I assume that this particular Xapian feature is unavailable in notmuch? > If so, I wonder if enabling has ever been considered? It is enabled, and documented in notmuch-search-terms(7). Unfortunately I don't think it's related to the original request. The mention of hyphenated words is about the input to the query parser, not the (necessarily) the retrieved text. d