help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Wildcard matching in debbugs-gnu-search - how?


From: Michael Albinus
Subject: Re: Wildcard matching in debbugs-gnu-search - how?
Date: Sat, 05 Oct 2019 12:27:45 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

Michael Heerdegen <address@hidden> writes:

Hi Michael,

>> > Hmm - OTOH the `debbugs-gnu-phrase-prompt' help echo says "If there is
>> > no operator between the words, AND is used by default.".  Should that be
>> > changed?
>>
>> I guess so, yes. Feel free to fix such errors.
>
> Ok, I fixed this one :)

Thanks! I've also tried to clarify in the debbugs user guide. The text
reads now

--8<---------------cut here---------------start------------->8---
 -- Command: debbugs-gnu-search
 -- Command: debbugs-org-search

     These both commands are completely interactive.  They ask for a
     '"search phrase"' for the text search.  It is just a string which
     contains the words to be searched for followed by each other.
     There are also operators like "AND", "ANDNOT" and "OR", which
     allow to search for words at different positions in the text.
     Only complete words, contained in a message body, are searched
     for.

     Wildcard searches are also supported.  It can be used for forward
     match search and backward match search of words.  For example,
     "[BW] euro" matches words which begin with "euro".  "[EW] sphere"
     matches words which end with "sphere".  Moreover, regular
     expressions are also supported.  For example, "[RX] ^inter.*al$"
     matches words which begin with "inter" and end with "al".(2)
     Several wildcards could be separated by the operators.  If there
     is no operator between the wildcards, "AND" is used by default.

     While the words to be searched for are case insensitive, the
     operators must be specified case sensitive.
--8<---------------cut here---------------end--------------->8---

Unfortunately, hyperestraier does not speak about the syntax of a word,
nowhere. Since it is written in Ruby, I guess it uses the syntax of a
Ruby identifier, see 
<https://ruby-doc.org/docs/ruby-doc-bundle/Manual/man-1.4/syntax.html#ident>:

--8<---------------cut here---------------start------------->8---
Ruby identifiers are consist of alphabets, decimal digits, and the
underscore character, and begin with a alphabets(including
underscore). There are no restrictions on the lengths of Ruby
identifiers.
--8<---------------cut here---------------end--------------->8---

This explains, why your example "[RX] ^el-search-.*-sources$" does not
work. Dashes don't belong to word syntax.

> Regards,
>
> Michael.

Best regards, Michael.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]