forked from nens/threedi-results-analysis
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
57 lines (49 loc) · 1.72 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
language: generic
dist: bionic
services:
- docker
cache:
directories:
- $HOME/docker-cache
before_install:
# Decrypt .coveralls.yml
- echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin
- >
openssl aes-256-cbc
-K $encrypted_1f076a31531a_key -iv $encrypted_1f076a31531a_iv
-in .coveralls.yml.enc
-out .coveralls.yml -d
# If the docker cache is still valid, use the cached docker image.
- >
scripts/travis-cache-ok.sh &&
cat $HOME/docker-cache/our-image.tar | docker load || true
install:
# Rebuild the docker image, but only if the docker cache isn't valid anymore.
- >
scripts/travis-cache-ok.sh ||
docker-compose build --build-arg uid=`id -u` --build-arg gid=`id -g`
script:
# We set the QT_QPA_PLATFORM to run the tests on a headless server:
# http://doc.qt.io/qt-5/embedded-linux.html
- docker-compose run -e QT_QPA_PLATFORM=offscreen qgis-desktop make test
- docker-compose run -e QT_QPA_PLATFORM=offscreen qgis-desktop make flake8
- docker-compose run qgis-desktop make docstrings
- docker-compose run qgis-desktop coveralls
- docker-compose run qgis-desktop make zip
before_cache:
# If the docker cache isn't valid, save the new docker image + checksum.
- mkdir -p $HOME/docker-cache
- >
scripts/travis-cache-ok.sh ||
docker save qgis-desktop > $HOME/docker-cache/our-image.tar
- scripts/travis-cache-ok.sh || scripts/create-travis-checksum.sh
# Deploy uploads the "make zip" result to https://artifacts.lizard.net, but
# only when building a tag. It then turns up on https://plugins.lizard.net
deploy:
provider: script
skip_cleanup: true
script: bash upload-artifact.sh
on:
tags: true
notifications:
email: false