Re: [PATCH] match_pathname(): give fnmatch one char of prefix context
From: Jeff King <hidden>
Date: 2025-10-14 03:09:16
From: Jeff King <hidden>
Date: 2025-10-14 03:09:16
On Mon, Oct 13, 2025 at 08:34:04PM -0400, Jeff King wrote:
On Fri, Oct 10, 2025 at 02:57:07PM +0000, Sruteesh Kumar wrote:quoted
Look at the first scenario in the above link. Git is matching the path foobar with the pattern foo**/bar which is against the git's official documentation (Look at the last point in the double asterisk section at the URL https://git-scm.com/docs/gitignore#_pattern_format). Is this an issue with the code or the documentation?I think the code is buggy. Here's a patch which would fix it, but I've marked it as RFC because:
Er, sorry, I forgot to actually mark it as "RFC" in the subject. But pretend that I did. ;) -Peff