forked from galaxyproject/training-material
-
Notifications
You must be signed in to change notification settings - Fork 1
/
.travis.yml
94 lines (88 loc) · 2.95 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
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
---
sudo: required
language: python
python: 3.6
branches:
only:
- gh-pages
- /.*/
addons:
chrome: stable
apt:
packages:
- libcurl4-openssl-dev
services:
- docker
env:
global:
- secure: AVbwBaVtCtTQCR4KC4gqnVeYSuE+gKFy5KgVWfKmog/eSJ60nQGLgCSJEwzzA5Q80vZkh9WFn5TmVHiSnSikMCQkUXPrux7vnwxSPkeLV23Vy3gOXDqyJQKHzVzuSsw2X7ikX9EAOaD8cn4McL1TwQqQK440gS1gudwFHZDCfdnqjMAVRW9eNVxq2kOfFMm7iUOd0uHl94fPxGQzAK7H8mGLwpphoWPgwsWO/JuIKWXE0gp6yTTZ1OuK2SrB9ZC2rURWeDHN5Q7NMHIeLjfD42NuAFAN5igZ+2CtzQKRCsO9C5vnuuvfby/yMmxrBKEkbWw0GWPanyNcKZ6j8kICIWwhSUt0Hc25gBE6BOn7aijqBCeJlwMKvVgUBASdg2P23Q2jOqy2o4n9iNAHmRKZtvrpBRhzdCu7lDVn4s7VVBfUwBj/e0+E9x1g0jbwofHo8j/BTjK0iDiHnC4O/IBneATeEcFx4bG6xg5+3uBt8/mLqG1BRUAZMz6SpBGi1PlL527t2Z3w5DNyKBzLDC3rborADdaxgjYH989vHakItq3RhiT8ZRGGfpULTnVO2gmFLCHGoVxKQX2RbTm5xiQ2aj5pnnhtYwKqPGSutdyUfJyxz/Av03NnEN65mv9TioA+sWLMKUL6KeJTT1+HcO5D01ZC7cpYc/M/S+gmff6O5eg=
matrix:
fast_finish: true
include:
- env: CHECK=lint
if: branch != gh-pages
- env: CHECK=slides
if: branch != gh-pages
- env: CHECK=site-build
if: branch != gh-pages
- env: CHECK=htmlproofer
- env: CHECK=htmlproofer-internal
- env: CHECK=pdf-generation
allow_failures:
- env: CHECK=htmlproofer
- env: CHECK=slides
- env: CHECK=pdf-generation
install:
- sudo apt-get update
- sudo update-ca-certificates
- sudo pip install awscli
- make install-conda
- export PATH="$HOME/miniconda3/bin:$PATH"
- conda config --set always_yes yes --set changeps1 no
- make create-env
- source activate galaxy_training_material
- make install
- if [[ $TRAVIS_EVENT_TYPE == "pull_request" ]]; then export ORIGIN_BRANCH=$TRAVIS_PULL_REQUEST_BRANCH; else export ORIGIN_BRANCH=$TRAVIS_BRANCH; fi
- if [[ $TRAVIS_EVENT_TYPE == "pull_request" ]]; then export ORIGIN_REPO=$TRAVIS_PULL_REQUEST_SLUG; else export ORIGIN_REPO=$TRAVIS_REPO_SLUG; fi
- echo $ORIGIN_REPO $ORIGIN_BRANCH
script:
# Check website
- |
set -e
if [ "$TRAVIS_BRANCH" == "gh-pages" ]
then
make check-links-gh-pages
else
if [ "$CHECK" == "htmlproofer" ]
then
make check-html
elif [ "$CHECK" == "htmlproofer-internal" ]
then
make check-html-internal
elif [ "$CHECK" == "lint" ]
then
make lint
elif [ "$CHECK" == "slides" ]
then
make check-slides
elif [ "$CHECK" == "site-build" ]
then
make build
elif [ "$CHECK" == "pdf-generation" ]
then
make pdf
fi
fi
after_success:
- |
if [ "$TRAVIS_PULL_REQUEST" == "false" -a "$TRAVIS_BRANCH" == "master" -a "$CHECK" == "site-build" ]
then
# update badges and instances and rebuild
make annotate
make build
bin/publish
elif [ "$TRAVIS_PULL_REQUEST" == "false" -a "$TRAVIS_TAG" != "" -a "$CHECK" == "site-build" ]
then
# Do not publish old versions live, and do not update badges since not pushing to gh-pages.
bin/publish-archive
fi