From: Junio C Hamano Date: Fri, 22 Jan 2010 00:51:06 GMT Subject: Re: [PATCH] Documentation: improve description of --glob=pattern and friends Message-ID: <7v1vhjj72d.fsf@alter.siamese.dyndns.org> In-Reply-To: Thomas Rast writes: > Consolidate the descriptions of --branches, --tags and --remotes a > bit, to make it less repetitive. Improve the grammar a bit, and spell > out the meaning of the 'append /*' rule. > > Signed-off-by: Thomas Rast > --- > > Compared to the earlier draft, I changed "it is anchored" (by > appending '/*') to "it is turned into a prefix match", since this is > not anchoring in the ^regex$ sense. (I guess 'leading-component > match' would be even more accurate, but that makes the sentence > unwieldy in my ears.) By the way, we may someday want to change that to do FNM_PATHNAME instead of just a flat glob. Incidentally, that is why I prefer the earlier suggestion to do "check with memcmp() if it is a path-prefix, and if it fails, then give fnmatch(FNM_PATHNAME) a chance". That way, we don't have to say "by appending '/*'" (which is an implementation detail we can change). It seems that the suggestion was ignored, though.