@@ -11,26 +11,27 @@ if [ "$TRAVIS" ]; then #running under travis
1111 if [ " $TRAVIS_BRANCH " = " master" ] && \
1212 [ " $TRAVIS_PULL_REQUEST " = " false" ] && \
1313 [ " $( ls -A " $TRAVIS_BUILD_DIR /doc" ) " ] ; then # not empty
14- git clone -- branch=gh-pages " https://${GH_TOKEN} @github.com/$TRAVIS_REPO_SLUG " gh-pages
14+ git clone -q -- branch=gh-pages " https://${GH_TOKEN} @github.com/$TRAVIS_REPO_SLUG " gh-pages > /dev/null 2>&1
1515 cd gh-pages || exit 1
16- rm -r css favicon.png fonts index.html interface js lists media module page proc \
17- program search.html sourcefile src tipuesearch type
16+ rm -rf -- css fonts interface lists module proc search.html src type favicon.png index.html \
17+ js media page program sourcefile tipuesearch || true
1818 cp -r " $TRAVIS_BUILD_DIR " /doc/* .
19- git add -A # Add all the new files
20- git commit -m " Development documentation updated by travis job $TRAVIS_JOB_NUMBER for commits $TRAVIS_COMMIT_RANGE "
21- git push origin gh-pages
19+ git add -A || true # Add all the new files
20+ git commit -m " Development documentation updated by travis job $TRAVIS_JOB_NUMBER for commits $TRAVIS_COMMIT_RANGE " || true
21+ git push -fq origin gh-pages > /dev/null 2>&1 || true
2222 fi
2323 # If publishing a new/updated tag, deploy it's documentation
2424 if [ " $TRAVIS_TAG " ] && [ " $( ls -A " $TRAVIS_BUILD_DIR /doc" ) " ] ; then # not empty
2525 cd " $TRAVIS_BUILD_DIR " || exit 1
26- git clone --branch=gh-pages " https://${GH_TOKEN} @github.com/$TRAVIS_REPO_SLUG " gh-pages
27- sed " 1 s/^/version: ${TRAVIS_TAG} \n/" json-fortran.md > json-fortran.tagged.md
26+ git clone -q --branch=gh-pages " https://${GH_TOKEN} @github.com/$TRAVIS_REPO_SLUG " gh-pages > /dev/null 2>&1
27+ sed " 2 s/^/version: ${TRAVIS_TAG} \n/" json-fortran.md > json-fortran.tagged.md
28+ head json-fortran.tagged.md # Debug output
2829 # rebuild FORD documentation without pages, with version info, wiping out any existing tag folder
29- ford -o " gh-pages/$TRAVIS_TAG " json-fortran.tagged.md
30+ ford --debug - o " gh-pages/$TRAVIS_TAG " json-fortran.tagged.md
3031 cd gh-pages || exit 1
3132 git add -A # add all new files in $TRAVIS_TAG/
3233 git commit -m " Tag/release documentation updated by travis job $TRAVIS_JOB_NUMBER for tag $TRAVIS_TAG $TRAVIS_COMMIT "
33- git push origin gh-pages
34+ git push -f -q origin gh-pages > /dev/null 2>&1
3435 fi
3536 fi
3637fi
0 commit comments