[GLLUG] Grep question

John Levin technolalia at gmail.com
Thu Oct 27 22:33:14 UTC 2022


Dear list,

Thanks very much to all who answered this query; it seems obvious when 
one knows the answer, but I was fixated on the stop, and not the dash.

John

On 27/10/2022 19:06, Philip Hands wrote:
> John Levin via GLLUG <gllug at mailman.lug.org.uk> writes:
> 
> ...
>> Is there something about the order of characters in regex square
>> brackets? Does the stop have a special meaning when given first?
> 
> The place to find the answer is in the regex(7) manpage:
> 
>    https://manpages.debian.org/testing/manpages/regex.7.en.html
> 
> in which you'll find this sentence regarding bracket expressions:
> 
>    To include a literal '-', make it the first or last character,
>    or the second endpoint of a range.
> 
>    (there's also more there about how to start a range with a `-`)
> 
> Cheers, Phil.



More information about the GLLUG mailing list