فهرست منبع

Build scripts: Don't try to commit nothing

Daniel Rudolf 9 سال پیش
والد
کامیت
b472664a20
2فایلهای تغییر یافته به همراه2 افزوده شده و 1 حذف شده
  1. 1 0
      _build/deploy-phpdoc-branch.sh
  2. 1 1
      _build/github-setup.sh

+ 1 - 0
_build/deploy-phpdoc-branch.sh

@@ -35,6 +35,7 @@ generate-phpdoc.sh \
     "$PHPDOC_GIT_DIR/phpDoc/$PHPDOC_ID.cache" "$PHPDOC_GIT_DIR/phpDoc/$PHPDOC_ID" \
     "Pico 1.0 API Documentation ($TRAVIS_BRANCH branch)"
 [ $? -eq 0 ] || exit 1
+[ -n "$(git status --porcelain "$PHPDOC_GIT_DIR/phpDoc/$PHPDOC_ID.cache")" ] || exit 0
 
 # commit phpDocs
 git add "$PHPDOC_GIT_DIR/phpDoc/$PHPDOC_ID"

+ 1 - 1
_build/github-setup.sh

@@ -32,4 +32,4 @@ git config user.email "travis-ci@picocms.org"
 if [ -n "$GITHUB_OAUTH_TOKEN" ]; then
     git config credential.helper 'store --file=.git/credentials'
     (umask 077 && echo "https://GitHub:$GITHUB_OAUTH_TOKEN@github.com" > .git/credentials)
-fi
+fi