File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11# This workflow will build a package using Maven and then publish it to GitHub packages when a release is created
22# For more information see: https://github.com/actions/setup-java#apache-maven-with-a-settings-path
33
4- name : Maven Package
4+ name : publish
55
66on :
77 release :
88 types : [created]
9+ workflow_dispatch :
10+ inputs :
11+ logLevel :
12+ description : ' Log level'
13+ required : true
14+ default : ' warning'
15+ tags :
16+ description : ' test, build and publish'
917
1018jobs :
1119 build :
2129 server-id : github # Value of the distributionManagement/repository/id field of the pom.xml
2230 settings-path : ${{ github.workspace }} # location for the settings.xml file
2331
24- - name : Build with Maven
32+ - name : compile and test
33+ run : mvn compile test --file pom.xml
34+
35+ - name : build source code
2536 run : mvn -B package --file pom.xml
2637
2738 - name : Publish to GitHub Packages Apache Maven
Original file line number Diff line number Diff line change 1+ # This workflow will build a package using Maven and then publish it to GitHub packages when a release is created
2+ # For more information see: https://github.com/actions/setup-java#apache-maven-with-a-settings-path
3+
4+ name : test
5+
6+ on :
7+ release :
8+ types : [created]
9+ workflow_dispatch :
10+ inputs :
11+ logLevel :
12+ description : ' Log level'
13+ required : true
14+ default : ' warning'
15+ tags :
16+ description : ' test'
17+
18+ jobs :
19+ build :
20+
21+ runs-on : ubuntu-latest
22+
23+ steps :
24+ - uses : actions/checkout@v2
25+ - name : Set up JDK 1.8
26+ uses : actions/setup-java@v1
27+ with :
28+ java-version : 1.8
29+
30+ - name : compile and test
31+ run : mvn compile test --file pom.xml
Original file line number Diff line number Diff line change @@ -7,7 +7,10 @@ branches:
77 - master
88
99jdk :
10- - oraclejdk9
10+ - oraclejdk11
11+ - openjdk11
12+
13+ before_install : " git clone -b travis `git config --get remote.origin.url` target/travis"
1114
1215addons :
1316 sonarcloud :
@@ -17,7 +20,7 @@ addons:
1720script :
1821 - >
1922 if [ "$TRAVIS_PULL_REQUEST" != "false" ];then
20- mvn org.jacoco:jacoco-maven-plugin:prepare-agent clean compile test -Dmaven.javadoc.skip=true;
23+ mvn org.jacoco:jacoco-maven-plugin:prepare-agent package --settings target/travis/settings.xml -Dsettings.security=target/travis/settings-security.xml -Dmaven.javadoc.skip=true;
2124 sonar-scanner
2225 fi
2326 - >
You can’t perform that action at this time.
0 commit comments