sourcetree中出现异常的line diff
Abnormal line diff appearing in sourcetree
我看到某些文件更改出现在 sourcetree 中,即使更改的内容完全相同。
Image taken from sourcetree
SourceTree 中使用的内部差异工具是默认工具。
如果有帮助,我正在使用可能正在编辑一些端线的 ReSharper。
How do check the raw ascii representations?
尝试:
git diff --word-diff-regex=.
您将看到 eol 更改(行尾字符)
在
之后尝试再次克隆您的存储库
git config --global core.autocrlf false
OP Shivku adds :
This helped me confirm that the file format was originally in UTF-8 BOM format, whilst ReSharper supposedly converts the file format into UTF-8 which removes the sequence of bytes EF BB BF from the file.
参见“What's different between UTF-8 and UTF-8 without BOM?”。
我看到某些文件更改出现在 sourcetree 中,即使更改的内容完全相同。 Image taken from sourcetree
SourceTree 中使用的内部差异工具是默认工具。 如果有帮助,我正在使用可能正在编辑一些端线的 ReSharper。
How do check the raw ascii representations?
尝试:
git diff --word-diff-regex=.
您将看到 eol 更改(行尾字符)
在
之后尝试再次克隆您的存储库git config --global core.autocrlf false
OP Shivku adds
This helped me confirm that the file format was originally in UTF-8 BOM format, whilst ReSharper supposedly converts the file format into UTF-8 which removes the sequence of bytes EF BB BF from the file.
参见“What's different between UTF-8 and UTF-8 without BOM?”。