Re: Branch Name Case Sensitivity

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

 



Karsten Blees <karsten.blees@xxxxxxxxx> writes:

>> If you are on a case-insensitive filesystem, or work on a cross-platform
>> project, ensure that you avoid ambiguous refs. Problem solved.
>> 
>
> So its OK to lose data if you accidentally use an ambiguous ref? I
> cannot believe you actually meant that.

I think he meant what he said: "you avoid ambiguous refs".  He did
not say "it is not Git's business to help you doing so".

I think it is prudent to warn in the end-user facing layer (read: do
not touch refs.c to implement something like that) when the user
creates "refs/heads/Next" when there already is "refs/heads/next",
and I further think it would make sense to do so even on case
sensitive platforms.

We warn ambiguous refs across refs hierarchies (e.g. if you have
refs/heads/next and refs/tags/next) with core.warnAmbiguousRefs; I
do not think it is a stretch to either introduce a new configuration
core.warnCaseInsensitiveRefs (auto-detected at the same place as we
auto-detect core.ignorecase) or use the same core.warnAmbiguousRefs
to trigger a warning upon seeing both "refs/heads/next" and
"refs/heads/Next".

--
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]