不同操系统下的换行符
CR回车 LF换行
Windows/Dos CRLF \r\n
Linux/Unix LF \n
MacOS CR \r

 

1、执行git config --get core.autocrlf

  https://blog.csdn.net/twilightdream/article/details/52020461

  https://www.cnblogs.com/warking/p/5718648.html

  

  1) 对已使用Windows换行符的文件,可以使用Sublime Text打开,

  View->Line Endings,选Unix,保存

 

  2)AutoCRLF

#提交时转换为LF,检出时转换为CRLF
git config --global core.autocrlf true   

#提交时转换为LF,检出时不转换
git config --global core.autocrlf input   

#提交检出均不转换
git config --global core.autocrlf false

 

 

2、https://www.cnblogs.com/fangshenghui/p/5693610.html

  解决方案:windows下面换行使用Unix风格。

  git config --get core.autocrlf ===》 false

 

相关文章:

  • 2022-12-23
  • 2021-08-10
  • 2021-07-23
  • 2021-08-24
  • 2021-10-18
  • 2021-10-19
  • 2022-01-12
猜你喜欢
  • 2021-08-26
  • 2021-10-21
  • 2021-09-16
  • 2021-06-25
  • 2021-12-05
相关资源
相似解决方案