遇到问题:
The file will have its original line endings in your working directory.
warning: CRLF will be replaced by LF in src/Presentation.Seedwork/Resources/Messages.Designer.cs.
The file will have its original line endings in your working directory.
分析问题:系统换行符不同导致,git是linux规范。
Window下的命令换行符是\r\n;Linux 下的命令换行符是\n;
Git 本身采用的规范是linux规范,也就是说文件在存储的时候,会有一些转换,一旦文件中有一些\r\n符号的话,它都会帮你换成\n。
解决方案:
运行git命令: git config core.filemode false
git config core.eol lf原理是:给你本地的repo设置一下。
本文介绍了一种常见的Git警告——关于CRLF与LF换行符冲突的问题及其解决方案。该问题通常发生在从Windows环境向Linux环境推送代码时。文章提供了具体的Git配置命令来解决此问题。
2114

被折叠的 条评论
为什么被折叠?



