git - Git 是否对 core.autocrlf 和 .gitattributes text=auto 使用相同的启发式?
问题描述
通过添加* text=auto
到 .gitattributes 文件,Git 使用自己的启发式方法来确定文件是否为文本,而不是二进制文件,以实现换行规范化。(资源)
据推测,Git 还需要一个启发式方法来确定它是否会在core.autocrlf = true
.
两种情况是否使用相同的启发式?
或者换句话说,在core.autocrlf=true
功能上等同于Windows 机器上* text=auto
的 .gitattributes 文件?core.eol=native
(除了 .gitattributes 是每个 repo 并且core.autocrlf
是每个用户/系统)
解决方案
推荐阅读
- javascript - 如何为 chrome 扩展上的当前文档执行 .querySelector()?
- python-3.x - 有没有一种pythonic方法来计算总计长达整分钟的对
- python - Django - 用于选择或添加到列表的自定义脆表单小部件
- java - What is the difference between "AdoptOpenJDK OpenJDK binaries" and "AdoptOpenJDK OpenJDK upstream binaries"
- node.js - Unit testing events with mocha
- google-cloud-platform - Can not deploy any revisions (old or first) to Cloud Run
- python - Python, Regular Expression, string to string with dots
- mysql - Mysql如何创建EQUAL约束?
- python - 如何从 zip 文件夹中的 csv 文件中读取数据并将 csv 文件中的数据保存到数据库中?
- django - 当用户上传图像时,我是否每次都必须运行 collectstatic 来提供图像?