git添加关于行结尾的警告,core.autocrlf为false

时间:2017-05-16 20:22:57

标签: windows git line-endings

我在网上阅读的所有内容都告诉我这不可能:

C:\Users\eric_\Code\range-v3>git add conanfile.py.in
warning: LF will be replaced by CRLF in conanfile.py.in.
The file will have its original line endings in your working directory.

C:\Users\eric_\Code\range-v3>git config core.autocrlf
false

为什么我不能让git忽略文件中的行结尾?

编辑:我在该目录中有一个.gitattributes文件,其中包含以下内容:

*.hpp text
*.cpp text
*.txt text
*.html text
*.md text
*.yml text
*.xml text
*.in text
.gitattributes text
.gitignore text

*.cmd -text
*.sln -text
*.vcxproj -text
*.vcxproj.filters -text

0 个答案:

没有答案