-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
43 lines (35 loc) · 1.16 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
# .travis.yml
# Travis-CI configuration file
sudo: required
addons:
# SonarCloud integration
sonarcloud:
organization: "haf-tech-github"
token:
secure: ${SQ_TOKEN}
language: java
jdk:
- oraclejdk8
before_install:
- mkdir -p output
# Build and generate documentation, including code coverage
script:
# general build
- cd blueprint-parent && mvn -B -V clean install
# generate documentation
- mvn -B -V generate-resources -Pdocumentation
# prepare the docs to output
- cp -R target/generated-docs/*/html/* ../output
# test coverage 1 - push sonarcloud.io
#- mvn org.jacoco:jacoco-maven-plugin:prepare-agent install sonar:sonar
- mvn org.jacoco:jacoco-maven-plugin:report-aggregate install sonar:sonar
# test coverage 2 - push to codecov.io
- cd ../target/jacoco && bash <(curl -s https://codecov.io/bash)
# Push the generated HTML docu to GitHub pages
after_success:
- cd ../../output ; rm -R .asciidoctor
- git init
- git config user.name "${GH_USER_NAME}"
- git config user.email "{GH_USER_EMAIL}"
- git add . ; git commit -m "Deploy to GitHub Pages - ${TRAVIS_COMMIT_RANGE}"
- git push --force "https://${GH_TOKEN}@${GH_REF}" master:gh-pages