From: David Roden Date: Mon, 5 May 2025 17:47:22 +0000 (+0200) Subject: 👷 Try to use toolchain definitions on Jenkins X-Git-Url: https://git.pterodactylus.net/?a=commitdiff_plain;h=ed47ab96180c5da2c58131ddb7b1560554e94ddb;p=msta.git 👷 Try to use toolchain definitions on Jenkins --- diff --git a/Jenkinsfile b/Jenkinsfile index 2701024..f57bcd7 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -11,7 +11,9 @@ pipeline { jdk 'OpenJDK 21' } steps { - sh './mvnw clean compile test-compile' + configFileProvider([configFile(fileId: 'fb50fa11-48a8-44b8-84fd-e11f06ab1067', targetLocation: 'toolchains.xml')]) { + sh './mvnw -t toolchains.xml clean compile test-compile' + } } } stage('Test') { @@ -19,7 +21,9 @@ pipeline { jdk 'OpenJDK 21' } steps { - sh './mvnw verify' + configFileProvider([configFile(fileId: 'fb50fa11-48a8-44b8-84fd-e11f06ab1067', targetLocation: 'toolchains.xml')]) { + sh './mvnw -t toolchains.xml verify' + } } post { always { @@ -33,9 +37,11 @@ pipeline { jdk 'OpenJDK 21' } steps { - sh './mvnw -DskipTests=true package' - archiveArtifacts artifacts: 'target/*.jar', fingerprint: true - javadoc javadocDir: 'target/apidocs', keepAll: true + configFileProvider([configFile(fileId: 'fb50fa11-48a8-44b8-84fd-e11f06ab1067', targetLocation: 'toolchains.xml')]) { + sh './mvnw -t toolchains.xml -DskipTests=true package' + archiveArtifacts artifacts: 'target/*.jar', fingerprint: true + javadoc javadocDir: 'target/apidocs', keepAll: true + } } } }