diff --git a/Jenkinsfile b/Jenkinsfile index 5853de2..fa2ba36 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -11,7 +11,7 @@ pipeline { } tools { - jdk 'Oracle Java 8' + jdk 'OpenJDK Java 17' maven 'Maven 3.5.2' git 'Default' } @@ -22,11 +22,17 @@ pipeline { defaultValue: false) } + parameters { + booleanParam(name: "RELEASE", + description: "Build a release from current commit.", + defaultValue: false) + } + stages { stage("Build & deploy SNAPSHOT to Nexus") { steps { - sh "mvn -B clean deploy -Pdocumentation" + sh "mvn -B clean deploy -Pdocumentation -pl :klass-api -am" } } @@ -39,7 +45,7 @@ pipeline { sshagent(['605c16cc-7c0c-4d39-8c8a-6d190e2f98b1']) { sh('git push --follow-tags') } - sh "mvn -B release:perform" + sh "mvn -B release:perform -pl :klass-api -am" } } diff --git a/pom.xml b/pom.xml index 0bf2d15..077e59d 100644 --- a/pom.xml +++ b/pom.xml @@ -51,6 +51,7 @@ 2.15.1 2.1.6 2.0.8.RELEASE + 1.31 @@ -106,6 +107,11 @@ -Pdocumentation -Dmaven.javadoc.skip=true + + org.apache.maven.plugins + maven-deploy-plugin + 3.1.1 +