-
Notifications
You must be signed in to change notification settings - Fork 5
/
.travis.yml
73 lines (65 loc) · 2.29 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
sudo: false
language: php
cache:
directories:
- "$HOME/.composer/cache"
- vendor
- "$HOME/.local"
php:
- 5.3
- 5.4
- 5.5
- 5.6
- 7.0
- 7.1
env:
global:
- COMPOSER_ARGS="--no-interaction --no-suggest"
- COMPOSER_ZPK_ARGS="--no-dev --classmap-authoritative"
- COMPOSER_DISCARD_CHANGES=1
- COVERAGE_DEPS="satooshi/php-coveralls"
# matrix:
# - DEPS=lowest
# - DEPS=latest
matrix:
fast_finish: true
include:
- php: 5.6
env:
# - DEPS=latest
- CS_CHECK=true
- TEST_COVERAGE=true
- php: 5.6
env:
# - DEPS=latest
- BUILD_ZPK="$(if [[ $TRAVIS_PULL_REQUEST == 'false' ]]; then echo -n 'true'; else echo -n 'false'; fi)"
- PATH="$HOME/.composer/vendor/bin:$HOME/.local/bin:$PATH"
exclude:
- php: 5.6
# env: DEPS=latest
before_install:
- if [[ $TEST_COVERAGE != 'true' ]]; then phpenv config-rm xdebug.ini || return 0 ; fi
- travis_retry composer self-update
install:
- if [[ $DEPS == 'latest' ]]; then travis_retry composer update -vvv $COMPOSER_ARGS ; fi
- if [[ $DEPS == 'lowest' ]]; then travis_retry composer update -vvv --prefer-lowest --prefer-stable $COMPOSER_ARGS ; fi
- if [[ $BUILD_ZPK == 'true' ]]; then travis_retry composer global require --dev $COMPOSER_ARGS phing/phing ; fi
- travis_retry composer install -vvv $COMPOSER_ARGS
- if [[ $TEST_COVERAGE == 'true' ]]; then travis_retry composer require --dev $COMPOSER_ARGS $COVERAGE_DEPS ; fi
- composer show
script:
- if [[ $TEST_COVERAGE == 'true' ]]; then composer test-coverage ; else composer test ; fi
- if [[ $BUILD_ZPK == 'true' ]]; then travis_retry composer install -vvv $COMPOSER_ARGS $COMPOSER_ZPK_ARGS ; fi
- if [[ $BUILD_ZPK == 'true' ]]; then composer show --installed ; fi
- if [[ $TRAVIS_TEST_RESULT == 0 && $BUILD_ZPK == 'true' ]]; then phing build ; fi
after_script:
- if [[ $TEST_COVERAGE == 'true' ]]; then composer upload-coverage ; fi
deploy:
- provider: releases
api_key:
secure: DomTGXybcR47TbiNl3I65M9N+qQZLxj22Dqr8W6SQq5/vUoR3BeUprZgYuOhcdWzmjLH0ZLIvn+JMDT8sP4fXkAzpOkeOQY166I6qw3fWXXp9wlh3RZqJghz7R3u+hNn/Md0fgZl1wrO+juNTedd3LVL4b0nKxbcenVFQmRjTEw=
file: "dist/ZendServerDeploymentHelper-${TRAVIS_TAG}.zpk"
skip_cleanup: true
on:
condition: $BUILD_ZPK = true
tags: true