Parcourir la source

调整build目录

lizw il y a 3 ans
Parent
commit
35856cf7d0
1 fichiers modifiés avec 6 ajouts et 2 suppressions
  1. 6 2
      build.sh

+ 6 - 2
build.sh

@@ -133,8 +133,12 @@ deployPush() {
   # 提交文件
   echo -e "$echoPrefix cd $pushPath $echoSuffix"
   cd "$pushPath"
-  git config user.name bot
-  git config user.name bot@git.com
+  if [ -n "$(git config user.name)" ]; then
+      echo -e "$echoPrefix git config user.name 'bot' $echoSuffix"
+      git config user.name 'bot'
+      echo -e "$echoPrefix git config user.name 'bot@git.com' $echoSuffix"
+      git config user.name 'bot@git.com'
+  fi
   echo -e "$echoPrefix git add -A $echoSuffix"
   git add -A
   if [ -n "$(git status -s)" ]; then