From c29caa2fb6349cf9966ab28639fd86d922809db6 Mon Sep 17 00:00:00 2001 From: HawkinC Macbook Date: Wed, 21 May 2025 14:03:30 +0800 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20fix(osx):=20=E4=BC=98=E5=8C=96gi?= =?UTF-8?q?t=E6=A3=80=E6=9F=A5=E9=80=BB=E8=BE=91=EF=BC=8C=E6=B7=BB?= =?UTF-8?q?=E5=8A=A0=E5=AE=89=E8=A3=85=E6=8F=90=E7=A4=BA=E5=92=8C=E9=85=8D?= =?UTF-8?q?=E7=BD=AE=E5=8A=A9=E6=89=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- config-os-and-apps.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/config-os-and-apps.sh b/config-os-and-apps.sh index 7d64fc1..fda42e7 100644 --- a/config-os-and-apps.sh +++ b/config-os-and-apps.sh @@ -9,10 +9,13 @@ BRANCH="dev" # INIT="" # 检查是否安装git -command -v git >/dev/null 2>&1 || { +if ! command -v git >/dev/null 2>&1; then echo "git命令未找到,请安装git" exit 1 -} +else + echo "git命令已安装,继续执行" + git config --global credential.helper store +fi # 使用getopts处理参数 while getopts ":hib:" opt; do