forked from brefphp/extra-php-extensions
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
41 lines (36 loc) · 976 Bytes
/
.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
language: minimal
notifications:
email:
on_success: never
services:
- docker
env:
- LAYER=amqp PHP="72 73 74"
- LAYER=blackfire PHP="72 73 74"
- LAYER=gmp PHP="72 73 74"
- LAYER=memcached PHP="72 73 74"
- LAYER=pgsql PHP="72 73 74"
- LAYER=xdebug PHP="72 73 74"
before_install:
- |
# tfold is a helper to create folded reports (From Symfony)
tfold () {
local title="$1"
local fold=$(echo $title | sed -r 's/[^-_A-Za-z0-9]+/./g')
shift
echo -e "travis_fold:start:$fold"
echo -e "\\e[1;34m$title\\e[0m"
bash -xc "$*" 2>&1
local ok=$?
(exit $ok) &&
echo -e "\\e[32mOK\\e[0m $title\\n\\ntravis_fold:end:$fold" ||
echo -e "\\e[41mKO\\e[0m $title\\n"
(exit $ok)
}
export -f tfold
script:
- cd layers/$LAYER
- |
for php_version in $PHP; do
tfold "Build $php_version" docker build --build-arg PHP_VERSION=${php_version} .
done