Pico/.travis.yml
2015-11-25 21:55:28 +01:00

52 lines
1.5 KiB
YAML

language: php
php:
- 5.3
- 5.4
- 5.5
- 5.6
- 7
- hhvm
- nightly
matrix:
allow_failures:
- php: nightly
fast-finish: true
install:
- composer install
before_script:
- export PATH="$TRAVIS_BUILD_DIR/vendor/bin:$PATH"
script:
- find . -not \( -path './vendor' -prune \) -type f -name '*.php' -print0 | xargs -0 -I file php -l file > /dev/null
after_success:
- |
[[ ",$DEPLOY_PHPDOC_BRANCHES," == *,"$TRAVIS_BRANCH",* ]] && [ "$TRAVIS_PHP_VERSION" == "5.3" ] && (
[ "$TRAVIS_SECURE_ENV_VARS" == "true" ] && [ -z "$TRAVIS_TAG" ] && (
./build/generate-phpdoc.sh . "build/phpdoc-master" "Pico 1.0 API Documentation (master)"
./build/deploy-phpdoc.sh "$TRAVIS_REPO_SLUG" "build/phpdoc-master" "master@$TRAVIS_COMMIT" "phpDoc/master" "gh-pages"
)
)
before_deploy:
- |
[ "$DEPLOY_PHPDOC_TAGS" == "true" ] && (
./build/generate-phpdoc.sh . "build/phpdoc-$TRAVIS_TAG" "Pico 1.0 API Documentation ($TRAVIS_TAG)"
./build/deploy-phpdoc.sh "$TRAVIS_REPO_SLUG" "build/phpdoc-$TRAVIS_TAG" "$TRAVIS_TAG" "phpDoc/$TRAVIS_TAG" "gh-pages"
)
- composer install --no-dev --optimize-autoloader
- tar -czf "pico-release-$TRAVIS_TAG.tar.gz" README.md LICENSE CONTRIBUTING.md CHANGELOG.md composer.json composer.lock config content-sample lib plugins themes vendor .htaccess index.php
deploy:
provider: releases
api_key: ${GITHUB_OAUTH_TOKEN}
file: pico-release-$TRAVIS_TAG.tar.gz
skip_cleanup: true
on:
tags: true
php: 5.3
sudo: false