diff --git a/.travis.yml b/.travis.yml index e3e53e6..9292c79 100644 --- a/.travis.yml +++ b/.travis.yml @@ -19,7 +19,7 @@ script: - phpunit after_success: - php vendor/bin/coveralls -v -c .coveralls.yml -- if [ $TRAVIS_PHP_VERSION = '5.6' ]; then sh generate-api.sh; fi +- if [ $TRAVIS_PHP_VERSION = '5.6' ] && [ $TRAVIS_BRANCH = 'master' ] && [ $TRAVIS_PULL_REQUEST = 'false' ]; then sh generate-api.sh; fi notifications: email: recipients: diff --git a/docs/index.html b/docs/index.html index 5fb879d..8fe74cb 100644 --- a/docs/index.html +++ b/docs/index.html @@ -6,7 +6,7 @@ - + PayPal PHP SDK - Welcome diff --git a/generate-api.sh b/generate-api.sh index f47b34a..be8c358 100644 --- a/generate-api.sh +++ b/generate-api.sh @@ -2,7 +2,7 @@ # Get ApiGen.phar wget http://www.apigen.org/apigen.phar -# Generate Api +# Generate SDK Docs php apigen.phar generate --template-theme="bootstrap" -s lib -d ../gh-pages/docs # Copy Home Page from Master Branch to Gh-Pages folder @@ -26,5 +26,5 @@ git checkout -B gh-pages # Push generated files git add . -git commit -m "API updated" +git commit -m "Docs updated by Travis" git push origin gh-pages -fq > /dev/null