Re: [PATCH 04/10] attr: more matching optimizations from .gitignore

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

 



On Sat, Oct 6, 2012 at 1:48 AM, Junio C Hamano <gitster@xxxxxxxxx> wrote:
> Nguyễn Thái Ngọc Duy <pclouds@xxxxxxxxx> writes:
>
>> +Unlike `.gitignore`, negative patterns are not supported.
>> +Patterns that match directories are also not supported.
>
> Is "are not supported" the right phrasing?
>
> I think it makes perfect sense not to forbid "!path attr1", because
> it is unclear what it means (e.g. "path -attr1" vs "path !attr1").
> So I would say "Negative patterns are forbidden as they do not make
> any sense".

OK

> But for the latter, I think it makes a lot more sense to just accept
> "path/ attr1" and doing nothing.  The user requests to set an
> attribute to "path" that has to be a directory, and there is nothing
> wrong in such a request in itself.  But nothing in git asks for
> attributes for directories (because we do not track directories),
> and such a request happens to be a no-op.

Or the user might think "path/ attr1" sets attr1 for all files under
"path/" because it does not make sense to attach attributes to a
directory in git.
-- 
Duy
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]