mirror of
https://github.com/GeWuYou/GFramework.git
synced 2026-05-06 16:16:44 +08:00
chore(config): 添加编辑器配置和 Git 属性设置
- 配置 .editorconfig 文件统一代码风格 - 设置 UTF-8 编码和 LF 行尾 - 为解决方案文件和批处理脚本配置 CRLF 行尾 - 配置 .gitattributes 统一文本文件行尾规范化 - 设置二进制文件不进行行尾转换 - 指定各类源码文件使用 LF 行尾
This commit is contained in:
parent
e513ecc284
commit
5a1232274e
18
.editorconfig
Normal file
18
.editorconfig
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
root = true
|
||||||
|
|
||||||
|
[*]
|
||||||
|
charset = utf-8
|
||||||
|
end_of_line = lf
|
||||||
|
insert_final_newline = true
|
||||||
|
|
||||||
|
[*.sln]
|
||||||
|
end_of_line = crlf
|
||||||
|
|
||||||
|
[*.bat]
|
||||||
|
end_of_line = crlf
|
||||||
|
|
||||||
|
[*.cmd]
|
||||||
|
end_of_line = crlf
|
||||||
|
|
||||||
|
[*.ps1]
|
||||||
|
end_of_line = crlf
|
||||||
35
.gitattributes
vendored
Normal file
35
.gitattributes
vendored
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
# Keep repository text normalized to LF unless a file format is known to require CRLF.
|
||||||
|
* text=auto eol=lf
|
||||||
|
|
||||||
|
# Solution and Windows-native scripts are more interoperable when they keep CRLF in the working tree.
|
||||||
|
*.sln text eol=crlf
|
||||||
|
*.bat text eol=crlf
|
||||||
|
*.cmd text eol=crlf
|
||||||
|
*.ps1 text eol=crlf
|
||||||
|
|
||||||
|
# Source, config, scripts, and documentation stay LF across WSL and Windows editors.
|
||||||
|
*.sh text eol=lf
|
||||||
|
*.cs text eol=lf
|
||||||
|
*.csproj text eol=lf
|
||||||
|
*.props text eol=lf
|
||||||
|
*.targets text eol=lf
|
||||||
|
*.json text eol=lf
|
||||||
|
*.yml text eol=lf
|
||||||
|
*.yaml text eol=lf
|
||||||
|
*.md text eol=lf
|
||||||
|
*.ts text eol=lf
|
||||||
|
*.js text eol=lf
|
||||||
|
*.mts text eol=lf
|
||||||
|
*.vue text eol=lf
|
||||||
|
*.css text eol=lf
|
||||||
|
|
||||||
|
# Common binary assets should never be line-normalized.
|
||||||
|
*.png binary
|
||||||
|
*.jpg binary
|
||||||
|
*.jpeg binary
|
||||||
|
*.gif binary
|
||||||
|
*.ico binary
|
||||||
|
*.zip binary
|
||||||
|
*.dll binary
|
||||||
|
*.so binary
|
||||||
|
*.pdb binary
|
||||||
Loading…
x
Reference in New Issue
Block a user