forked from git/git
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Closed
git-for-windows/build-extra
#624Milestone
Description
Because core.ignorecase defaults to true on Windows, the *.rtf diff=astextplain line in /etc/gitattributes also applies to *.Rtf files with a mixed-case extension; but /usr/bin/astextplain does not recognize the mixed-case extension and fails.
Found by cloning https://github.com/microsoft/Windows-classic-samples and attempting use git log -S. For example:
$ git log -SCreateRemoteThread 2b94df5730177ec27e726b60017c01c97ef1a8fb -- Samples/Win7Samples/winbase/winnt/perftool
E: unsupported filetype C:\Users\Kalle\AppData\Local\Temp/git-blob-a23156/StatList.Rtf
fatal: unable to read files to diff
In this case, the error is due to Samples/Win7Samples/winbase/winnt/perftool/pdh/statlist/StatList.Rtf.
Workarounds:
git -c core.ignorecase=false, to prevent*.rtffrom matchingStatList.Rtf- add
*.rtf !diffto.git/info/attributes, to disableastextplainfor RTF files altogether
This is git version 2.49.0.windows.1.
Reactions are currently unavailable