当我在Windows上克隆一个使用msysgit使用LF行结束的存储库时,签出的文件有一些CRLF行结束,即使我的core.autocrlf被设置为false。为什么会这样呢?
示例:
> git config core.autocrlf
false
> git clone https://github.com/wp-cli/wp-cli.git wp-cli签出的文件有CRLF行尾,即使它们在存储库本身中有LF。
发布于 2014-11-13 13:23:31
项目中有一个.gitattributes文件
# Auto detect text files and perform EOL normalization
* text=auto这比core.autocrlf具有更高的优先级。
请参阅http://git-scm.com/docs/gitattributes
发布于 2014-11-13 13:23:23
.gitattributes和wp存储库中的有这样的档案也会影响到这一点.
https://stackoverflow.com/questions/26909803
复制相似问题