Re: Single brackets matching in .gitignore rules
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Sep 28, 2015, 17:40 UTC
- Message-ID
- <xmqq7fnae92a.fsf@gitster.mtv.corp.google.com>
- In-Reply-To
- <CACsJy8DiTevhSnkkab-kfvpibitoUMHdjC2UdGT244JwLRxqWQ@mail.gmail.com>
Duy Nguyen <pclouds@gmail.com> writes:
Show 6 quoted lines
> This is already answered. I just want to add that C Git has stopped > using system fnmatch for some time (part of the reason is system > fnmatch behaves differently in corner cases). If you don't mind C, > have a look at dowild() in wildmatch.c, or t/t3070-wildmatch.sh for > some corner cases (but your cases aren't there, may be worth adding > too)
What exactly are you suggesting to "fix", though? Barf when an unmatched ] appears as a part of the pattern, instead of taking it literally?