相关疑难解决方法(0)

.gitattributes中`*text = auto`和`*text eol = lf`之间的差异是什么?

我一遍又一遍地看着.gitattributes的文档,但我找不到这两者之间的差异的明确答案:

* text=auto

* text eol=lf

text=auto仅用于*或者也可以与特定扩展一起使用?在这种情况下,有什么不同?

*.txt text=auto

*.txt text eol=lf

git gitattributes core.autocrlf

4
推荐指数
1
解决办法
1291
查看次数

.gitattributes 中的“* text=auto eol=lf”和“* text eol=lf”有什么区别?

这与这个问题非常相似: What is the Difference between `* text=auto` and `* text eol=lf` in .gitattributes?

但我特别问为什么我应该使用* text=auto eol=lfover* text eol=lf或反之亦然?

根据我的理解,eol覆盖text设置,那么使用前者有什么意义呢?有区别吗?如果是这样 - 怎么办?

我现在正在阅读很多网站和 Stack Overflow 问题/答案 - 但我仍然完全困惑。特别是当我看到这个变化时:https://github.com/git/git/blob/master/Documentation/RelNotes/2.10.0.txt#L248

我发现更改的措辞很难读懂,以至于我现在仍然不明白。有人可以解释一下吗?

git gitattributes

3
推荐指数
1
解决办法
1479
查看次数

标签 统计

git ×2

gitattributes ×2

core.autocrlf ×1