forked from alfasoftware/morf
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
46 lines (46 loc) · 2.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
language: java
install: true
addons:
sonarcloud:
organization: "alfasoftware"
token:
secure: "Rk0cQ9JL2/DB8xrKjaU/m9HEvZllokUZ8c7Q+6g3DHwOsMvZi1OoCdUtDXf9Zl0xtdFPMvoWsGPeZ6+sZK9evHscvRH83hVMTrTabWK4+QL660QeMXboBprwuBIpAI0XBCfNcslsT3zPd/e4v35FHPdvRr1yOQlibrjEgs1MZo6/LQ7QgRNJAHsskiqOOJS6LLDHceYJEW7wd/y7R0BvXoxch6xQhDOFvowoc22/cEyUVCSCMMas74hD//veSXdHt0CNOY+H+/PAzAYsbM0rkJnrysqO8UgLZwpnP/Mjsoi0InoisvriSl9MYgQwMAfcrtVxxR94vt4Pu62LXsnt6ufGfwFBrdTh1Rna05fzTAmm9bwywIR2UsMwNeM4iDoz+Rc2ImnwMKRipn5lib5kCOlwqjTv6NVi0oV5XEzTfU51HIrQMmmsq60YwMZgcYwckHoVVOojv29dAjLe0Z/LbfUH8MHprt8/MdWA8ir2egxHHW3dXVY11MgDKzQ2RyYb1uPNJgkVfZDm7uHDcj13dFR61Gy1mTdrtpnWx1ojU2IJQ4oKuGb04RbqQ5lCq7dgsHlaeaAJFMlcn1I6IOk8t6QkYy/3vhSXgkZpQAO3K5Zp4aaGZD90sYdQO3JQNCe2S8mhgEGOqsAdxytFygCaMxOKG5NV9qxVilkzfGPvmqM="
jdk: openjdk17
dist: xenial
jobs:
include:
- if: repo = alfasoftware/morf AND branch = main AND NOT type = pull_request
name: "Test"
script:
- git fetch --unshallow --quiet
- mvn clean verify sonar:sonar -Pcoverage -B -U
- if: repo = alfasoftware/morf AND NOT branch = main AND NOT type = pull_request
name: "Test"
script:
- git fetch --unshallow --quiet
- mvn clean verify sonar:sonar -Pcoverage -B -U -Dsonar.branch.name=$TRAVIS_BRANCH
- if: repo = alfasoftware/morf AND head_repo = alfasoftware/morf AND type = pull_request
name: "Test"
script:
- git fetch --unshallow --quiet
- mvn clean verify sonar:sonar -Pcoverage -B -U -Dsonar.pullrequest.key=$TRAVIS_PULL_REQUEST -Dsonar.pullrequest.branch=$TRAVIS_PULL_REQUEST_BRANCH -Dsonar.pullrequest.base=$TRAVIS_BRANCH
- if: repo = alfasoftware/morf AND branch = main AND NOT type = pull_request
name: "Deploy From Main"
script:
- echo $GPG_SECRET_KEYS | base64 --decode | $GPG_EXECUTABLE --import
- echo $GPG_OWNERTRUST | base64 --decode | $GPG_EXECUTABLE --import-ownertrust
- mvn clean deploy --settings .maven-settings.xml -B -U -Prelease
- if: repo = alfasoftware/morf AND tag IS present AND NOT type = pull_request AND sender in (capgen628, gilleain, jsimlo, therealluigi, okeating, wnicholson)
name: "Deploy From Tag"
script:
- echo $GPG_SECRET_KEYS | base64 --decode | $GPG_EXECUTABLE --import
- echo $GPG_OWNERTRUST | base64 --decode | $GPG_EXECUTABLE --import-ownertrust
- mvn clean deploy --settings .maven-settings.xml -B -U -Prelease
- if: (repo = alfasoftware/morf AND NOT head_repo = alfasoftware/morf AND type = pull_request) OR NOT repo = alfasoftware/morf
name: "Test"
script:
- mvn clean test -B -U
cache:
directories:
- '$HOME/.m2/repository'
- '$HOME/.sonar/cache'