chore: add .gitattributes to fix cross-platform line endings

This commit is contained in:
2026-06-26 05:26:07 +08:00
parent 773639fd7c
commit f527c91c27
2 changed files with 18 additions and 1 deletions

17
.gitattributes vendored Normal file
View File

@@ -0,0 +1,17 @@
# 跨平台行尾:仓库内统一 LF避免 Windows autocrlf 造成「假 modified」
* text=auto eol=lf
# Windows 批处理在 cmd 下需要 CRLF
*.bat text eol=crlf
*.cmd text eol=crlf
# 二进制
*.png binary
*.jpg binary
*.jpeg binary
*.gif binary
*.ico binary
*.webp binary
*.woff binary
*.woff2 binary
*.exe binary

View File

@@ -1,4 +1,4 @@
@echo off @echo off
REM 姜十三论坛 Windows 快捷构建(双击或命令行均可) REM Jiang13 Forum Windows build wrapper (double-click or run from cmd)
powershell -NoProfile -ExecutionPolicy Bypass -File "%~dp0build.ps1" %* powershell -NoProfile -ExecutionPolicy Bypass -File "%~dp0build.ps1" %*
exit /b %ERRORLEVEL% exit /b %ERRORLEVEL%