forked from blallo/rss-bridge
[.travis.yml] Fix configuration to work with Ubuntu Trusty
Travis CI upgraded the linux build environment from Ubuntu Precise to Ubuntu Trusty with Trusty becoming the default build environment as of August 2017: https://docs.travis-ci.com/user/reference/overview/ A bug in the configuration of the Ubuntu Trusty distro causes all builds except nightly to fail. The PHP include_path is set to include_path='.:/home/travis/.phpenv/versions/5.6.31/share/pear' instead of include_path='.:/home/travis/.phpenv/versions/5.6.31/lib/php/pear' which causes phpcs to fail because it cannot resolve import paths. This commit adds a hotfix to .travis.yml that circumvents the issue by overwriting the include_path during initialization. This hotfix should be removed once a solution is found. This bug is tracked via https://github.com/travis-ci/travis-ci/issues/8487
This commit is contained in:
parent
1ea091f215
commit
e671a2ad02
1 changed files with 15 additions and 1 deletions
16
.travis.yml
16
.travis.yml
|
@ -1,4 +1,4 @@
|
|||
dist: precise
|
||||
dist: trusty
|
||||
language: php
|
||||
php:
|
||||
- '5.6'
|
||||
|
@ -6,6 +6,20 @@ php:
|
|||
- hhvm
|
||||
- nightly
|
||||
|
||||
before_install:
|
||||
# Circumvent a bug in current Travis CI builds using Ubuntu Trusty, where the
|
||||
# include_path is wrong.
|
||||
#
|
||||
# Default is:
|
||||
# - include_path='.:/home/travis/.phpenv/versions/5.6.31/share/pear'
|
||||
#
|
||||
# Should be:
|
||||
# - include_path='.:/home/travis/.phpenv/versions/5.6.31/lib/php/pear'
|
||||
#
|
||||
# This applies to all builds except hhvm and nightly. Once the distro is fixed
|
||||
# the following line can be removed
|
||||
- if [[ ${TRAVIS_PHP_VERSION:0:1} == "5" || ${TRAVIS_PHP_VERSION:0:1} == "7" ]]; then echo "include_path='.:/home/travis/.phpenv/versions/$(phpenv version-name)/lib/php/pear'" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini; fi
|
||||
|
||||
install:
|
||||
- pear channel-update pear.php.net
|
||||
- pear install PHP_CodeSniffer
|
||||
|
|
Loading…
Reference in a new issue