2019-01-14 03:59:36 +01:00
|
|
|
dist: xenial
|
2016-12-07 06:01:49 +01:00
|
|
|
language: php
|
2016-12-07 06:16:15 +01:00
|
|
|
|
2018-08-07 19:54:02 +02:00
|
|
|
env:
|
2018-08-02 06:44:15 +02:00
|
|
|
global:
|
2020-08-23 16:32:07 +02:00
|
|
|
- DEFAULT_COMPOSER_FLAGS="--no-interaction --no-suggest --prefer-dist"
|
2018-08-02 06:44:15 +02:00
|
|
|
- XDEBUG="false"
|
2018-11-28 22:41:13 +01:00
|
|
|
# generated with travis encrypt -r vimeo/psalm --org GITHUB_TOKEN="<secret oauth token>"
|
|
|
|
- secure: Ayjp10v6IWeJX3ThWvPxlv0gkuTuvu30lsdQCjop+vS0Kv+6/IEOdSOxtm0tEWacq9EFCViWRKh9zxiwPtoi0wxGdzGGws+UtIJxew6Vy8HDCEH8nY4k50eElKUWI4YhVbiSdZEZ+Bd9kO0qGEBH9iWh8Tc8MP2Hklx7lOf+zUTSm8vpv+idcCxwGCvQMaMc5NhfnkgGq95/UU3iOvCi5/wkIFnSnoccxmZE2zsxI1e355ipa0uoe8/Ml6vK0NrZ0aBZwZfItsIuhRcL4Cm5kyar+Ao/mn9Zw8CHbfESrIMomRI7ZxwPNFj+sR/wCvEasIGHRxH8B9F4d8SmAoHR1CrmM/zyWRon73CfRb56M4VGG1hyqTr1GYHpBgZKSOYA8TKyOjD8EHGvevfHpJoGVNxf0+vAfdizlVJvkYhzSz/VjpOZO8rfOct4deNcpCVuVGg5uOGeg5P7coVniGHLHTm3JozK9Ia+ZLePtr3l/NuoW5dXVF1fdroCyQS2X0VSXALnnTPzcIQYsmpCk8yJ8uXorxj4dJHhstyll1jemJjxT7HJ1ASPUOTsPu9u9EoBDHQxOGa5b2/7chyV+EhrYV899RKZ4xEPzpC619sWgtZJci3oLcebU1BY42pIr94UqtwcJKhriwV72VpKvCG/eqOKLhXq355TYRx2dK05a5w=
|
2016-12-07 06:16:15 +01:00
|
|
|
|
|
|
|
cache:
|
|
|
|
directories:
|
2020-08-23 16:32:07 +02:00
|
|
|
- $(composer config cache-files-dir)
|
|
|
|
- $(composer config cache-vcs-dir)
|
2016-12-07 06:16:15 +01:00
|
|
|
|
2018-01-09 07:09:52 +01:00
|
|
|
before_install:
|
|
|
|
# determine INI file
|
2020-04-08 15:04:36 +02:00
|
|
|
- composer config --global discard-changes true
|
2018-07-13 23:44:50 +02:00
|
|
|
- export INI_DIR=~/.phpenv/versions/$(phpenv version-name)/etc/conf.d
|
|
|
|
- export INI=$INI_DIR/travis.ini
|
2019-03-01 23:32:52 +01:00
|
|
|
- if [[ "$TRAVIS_TAG" = '' ]]; then export COMPOSER_ROOT_VERSION=dev-master; fi
|
2018-01-09 07:09:52 +01:00
|
|
|
# disable default memory limit
|
|
|
|
- echo memory_limit = 2G >> $INI
|
2018-08-02 06:44:15 +02:00
|
|
|
- if [[ "$XDEBUG" = 'false' && -f $INI_DIR/xdebug.ini ]]; then phpenv config-rm xdebug.ini; fi
|
2019-08-21 17:32:50 +02:00
|
|
|
- if [[ $TRAVIS_PHP_VERSION = nightly ]]; then export DEFAULT_COMPOSER_FLAGS="$DEFAULT_COMPOSER_FLAGS --ignore-platform-reqs"; fi
|
2020-01-12 16:43:30 +01:00
|
|
|
- composer validate
|
2018-01-09 07:09:52 +01:00
|
|
|
|
2020-04-08 15:04:36 +02:00
|
|
|
|
2016-12-07 06:16:15 +01:00
|
|
|
install:
|
2018-08-02 06:44:15 +02:00
|
|
|
- if [[ "$DEPS" = 'high' ]]; then travis_retry composer $DEFAULT_COMPOSER_FLAGS update; fi
|
|
|
|
- if [[ "$DEPS" = 'low' ]]; then travis_retry composer $DEFAULT_COMPOSER_FLAGS --prefer-lowest --prefer-stable update; fi
|
2016-12-23 20:45:20 +01:00
|
|
|
|
|
|
|
script:
|
2020-08-23 16:32:07 +02:00
|
|
|
- vendor/bin/paratest --runner=WrapperRunner
|
2019-12-03 04:20:47 +01:00
|
|
|
- ./psalm
|
2017-12-14 06:40:22 +01:00
|
|
|
|
2020-02-07 18:08:21 +01:00
|
|
|
# Additional stages
|
|
|
|
jobs:
|
2020-02-07 18:15:50 +01:00
|
|
|
fast_finish: true
|
2018-08-02 06:44:15 +02:00
|
|
|
include:
|
2020-08-30 17:44:14 +02:00
|
|
|
- php: 7.3
|
2020-02-07 18:15:50 +01:00
|
|
|
env: DEPS="low"
|
|
|
|
|
2020-08-30 17:44:14 +02:00
|
|
|
- php: 7.3
|
2020-02-07 18:15:50 +01:00
|
|
|
env: DEPS="high"
|
|
|
|
|
|
|
|
- php: 7.4
|
|
|
|
env: DEPS="low"
|
|
|
|
|
|
|
|
- php: 7.4
|
|
|
|
env: DEPS="high"
|
|
|
|
|
|
|
|
- php: 7.3
|
2018-08-02 06:44:15 +02:00
|
|
|
env: DEPS="high"
|
|
|
|
script:
|
|
|
|
- vendor/bin/phpcs
|
|
|
|
|
2020-02-07 18:15:50 +01:00
|
|
|
- php: 7.3
|
2020-01-01 19:55:33 +01:00
|
|
|
env: DEPS="high"
|
|
|
|
script:
|
|
|
|
- composer require --dev maglnet/composer-require-checker:^2.0.0
|
2020-01-01 22:43:36 +01:00
|
|
|
- ./vendor/bin/composer-require-checker check --config-file=bin/composer-require-checker-config.json ./composer.json
|
2020-01-01 19:55:33 +01:00
|
|
|
|
2020-02-07 18:15:50 +01:00
|
|
|
- php: 7.3
|
2019-06-09 01:51:40 +02:00
|
|
|
env: DEPS="high"
|
2019-06-01 16:25:26 +02:00
|
|
|
script: bin/build-phar.sh
|
2018-08-02 06:44:15 +02:00
|
|
|
deploy:
|
2019-06-01 18:51:33 +02:00
|
|
|
# deploy tagged releases to github releases page
|
2019-06-01 16:25:26 +02:00
|
|
|
- provider: releases
|
|
|
|
skip_cleanup: true
|
|
|
|
on:
|
|
|
|
tags: true
|
2019-06-01 18:51:33 +02:00
|
|
|
repo: vimeo/psalm
|
2019-06-01 16:25:26 +02:00
|
|
|
api_key: $GITHUB_TOKEN
|
|
|
|
file:
|
|
|
|
- build/psalm.phar
|
|
|
|
- build/psalm.phar.asc
|
2019-06-01 18:51:33 +02:00
|
|
|
|
2019-06-05 01:14:12 +02:00
|
|
|
# deploy built phar to github.com/psalm/phar repo for all branches and tags,
|
2019-06-01 18:51:33 +02:00
|
|
|
# but not for pull requests
|
2019-06-01 16:25:26 +02:00
|
|
|
- provider: script
|
|
|
|
skip_cleanup: true
|
2019-06-01 18:51:33 +02:00
|
|
|
on:
|
2019-06-02 09:55:40 +02:00
|
|
|
all_branches: true
|
2019-06-01 18:51:33 +02:00
|
|
|
condition: ' "$TRAVIS_PULL_REQUEST" = "false" '
|
2019-06-01 16:25:26 +02:00
|
|
|
script: bin/travis-deploy-phar.sh
|