re[6]: sparse checkout file with windows line endings doesn't work

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

 



Thanks Duy for the fast response.

> Anyway there is a trailing space at the
>>  end of the rule. This is the content of your sparse checkout file in C
>>  syntax
>>
>>  "/CONFIGURATION\x20\r\n"
>>
>>  Maybe we could warn about trailing spaces.. Stripping them
>>  automatically is a possibility, but we need an escape hatch for
>>  (crazy?) people who actually have trailing spaces in there paths.

Yuk eh?

I just discovered that if you do

echo /CONFIGURATION      > .git\info\sparse-checkout

in Windows, you get 5 training spaces!

Man, I hate Windows!

Something that would help is an easier way to debug sparse-checkout rules.

When something goes wrong, there appears to be no way to understand what
git thinks it's reading.   I'm not sure if such a way, if it existed, would help with
trailing spaces, but if you could say

git read-tree -muv HEAD

and it would say

reading '.git\info\sparse-checkout'...
rule '/CONFIGURATION ' - no matches

that would solve actually two problems:

1) You can see that it thinks there is a space there

2) the config file name is sparse-checkout, with a dash, not sparsecheckout...
a mistake I made that had me scratching my head for some time, since everywhere
else it doesn't have a dash!

Thanks again for your quick help.

Martin

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