From 1ab8a343fd7e3f84550c340aaa1531ca995d8d87 Mon Sep 17 00:00:00 2001 From: liufumingren Date: Fri, 25 Sep 2026 17:06:08 +0800 Subject: [PATCH] =?UTF-8?q?chore:=20=E6=96=B0=E5=A2=9E=20.gitattributes?= =?UTF-8?q?=EF=BC=88*.sh=20=E5=BC=BA=E5=88=B6=20LF=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 本机 core.autocrlf=true,重新 checkout 会把 scripts/*.sh 变成 CRLF; 这些脚本要 adb push 到 Android 上执行,CRLF 会让 shebang 变成 "#!/system/bin/sh\r" 而报 not found,因此固定为 LF。 --- .gitattributes | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 .gitattributes diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..91dce4c --- /dev/null +++ b/.gitattributes @@ -0,0 +1,3 @@ +# Android/设备端脚本必须以 LF 落地: +# CRLF 会让 shebang 变成 "#!/system/bin/sh\r",adb push 到平板后执行即报 "not found"。 +*.sh text eol=lf