Skip to content

Commit 1ab6c5c

Browse files
committed
chore: add .gitattributes for consistent line endings
1 parent d33b5a7 commit 1ab6c5c

1 file changed

Lines changed: 33 additions & 0 deletions

File tree

.gitattributes

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
# 自动处理行尾符
2+
* text=auto
3+
4+
# Java 和 XML 文件使用 LF 行尾符
5+
*.java text eol=lf
6+
*.xml text eol=lf
7+
8+
# Vue 和 TypeScript 文件使用 LF
9+
*.vue text eol=lf
10+
*.ts text eol=lf
11+
*.tsx text eol=lf
12+
*.js text eol=lf
13+
*.jsx text eol=lf
14+
15+
# Python 文件使用 LF
16+
*.py text eol=lf
17+
18+
# 配置文件使用 LF
19+
*.json text eol=lf
20+
*.yaml text eol=lf
21+
*.yml text eol=lf
22+
*.properties text eol=lf
23+
24+
# 确保二进制文件不被修改
25+
*.jar binary
26+
*.png binary
27+
*.jpg binary
28+
*.gif binary
29+
*.ico binary
30+
*.woff binary
31+
*.woff2 binary
32+
*.ttf binary
33+
*.eot binary

0 commit comments

Comments
 (0)