Verified Commit 73d46c0f authored by Johannes Visintini's avatar Johannes Visintini
Browse files
parent ef3e7a6f
Pipeline #1842 created
......@@ -3,12 +3,12 @@
<component name="CheckStyle-IDEA">
<option name="configuration">
<map>
<entry key="active-configuration" value="HTTP_URL:https://gitlab.gistools.geog.uni-heidelberg.de/giscience/big-data/ohsome/parent/raw/2.8/ohsome-codestyle/src/main/resources/checkstyle-google-ohsome.xml:ohsome Google Checks" />
<entry key="active-configuration" value="HTTP_URL:https://gitlab.gistools.geog.uni-heidelberg.de/giscience/big-data/ohsome/parent/raw/2.10/ohsome-codestyle/src/main/resources/checkstyle-google-ohsome.xml:ohsome Google Checks" />
<entry key="checkstyle-version" value="8.35" />
<entry key="copy-libs" value="false" />
<entry key="location-0" value="BUNDLED:(bundled):Sun Checks" />
<entry key="location-1" value="BUNDLED:(bundled):Google Checks" />
<entry key="location-2" value="HTTP_URL:https://gitlab.gistools.geog.uni-heidelberg.de/giscience/big-data/ohsome/parent/raw/2.8/ohsome-codestyle/src/main/resources/checkstyle-google-ohsome.xml:ohsome Google Checks" />
<entry key="location-2" value="HTTP_URL:https://gitlab.gistools.geog.uni-heidelberg.de/giscience/big-data/ohsome/parent/raw/2.10/ohsome-codestyle/src/main/resources/checkstyle-google-ohsome.xml:ohsome Google Checks" />
<entry key="property-2.org.checkstyle.google.suppressionfilter.config" value="" />
<entry key="property-2.org.checkstyle.google.suppressionxpathfilter.config" value="" />
<entry key="scan-before-checkin" value="false" />
......
pipeline {
agent {label 'main'}
options {
timeout(time: 30, unit: 'MINUTES')
}
environment {
REPO_NAME = sh(returnStdout: true, script: 'basename `git remote get-url origin` .git').trim()
VERSION = sh(returnStdout: true, script: 'mvn org.apache.maven.plugins:maven-help-plugin:2.1.1:evaluate -Dexpression=project.version | grep -Ev "(^\\[|Download\\w+)"').trim()
VERSION = sh(returnStdout: true, script: 'mvn --batch-mode org.apache.maven.plugins:maven-help-plugin:2.1.1:evaluate -Dexpression=project.version | grep -Ev "(^\\[|Download\\w+)"').trim()
LATEST_AUTHOR = sh(returnStdout: true, script: 'git show -s --pretty=%an').trim()
LATEST_COMMIT_ID = sh(returnStdout: true, script: 'git describe --tags --long --always').trim()
......@@ -44,7 +47,7 @@ pipeline {
rtMaven.deployer.deployArtifacts = false
withCredentials([string(credentialsId: 'gpg-signing-key-passphrase', variable: 'PASSPHRASE')]) {
buildInfo = rtMaven.run pom: 'pom.xml', goals: 'clean compile javadoc:jar source:jar verify -P jacoco,sign,git -Dmaven.repo.local=.m2 $MAVEN_TEST_OPTIONS -Dgpg.passphrase=$PASSPHRASE'
buildInfo = rtMaven.run pom: 'pom.xml', goals: '--batch-mode clean compile javadoc:jar source:jar verify -P jacoco,sign,git -Dmaven.repo.local=.m2 $MAVEN_TEST_OPTIONS -Dgpg.passphrase=$PASSPHRASE'
}
}
}
......@@ -59,7 +62,7 @@ pipeline {
steps {
script {
withSonarQubeEnv('sonarcloud GIScience/ohsome') {
sh "mvn sonar:sonar -Dsonar.branch.name=${env.BRANCH_NAME}"
sh "mvn --batch-mode sonar:sonar -Dsonar.branch.name=${env.BRANCH_NAME}"
}
report_basedir = "/srv/reports/${REPO_NAME}/${VERSION}_${env.BRANCH_NAME}/${env.BUILD_NUMBER}_${LATEST_COMMIT_ID}"
......@@ -77,13 +80,13 @@ pipeline {
// infer
if (env.BRANCH_NAME ==~ INFER_BRANCH_REGEX) {
report_dir = report_basedir + "/infer/"
sh "mvn clean"
sh "infer run --pmd-xml -r -- mvn compile"
sh "mvn --batch-mode clean"
sh "infer run --pmd-xml -r -- mvn --batch-mode compile"
sh "mkdir -p ${report_dir} && rm -Rf ${report_dir}* && cp -R ./infer-out/* ${report_dir}"
}
// warnings plugin
rtMaven.run pom: 'pom.xml', goals: '--batch-mode -V -e clean compile checkstyle:checkstyle pmd:pmd pmd:cpd com.github.spotbugs:spotbugs-maven-plugin:3.1.7:spotbugs -Dmaven.repo.local=.m2'
rtMaven.run pom: 'pom.xml', goals: '--batch-mode -V -e clean compile checkstyle:checkstyle pmd:pmd pmd:cpd spotbugs:spotbugs -Dmaven.repo.local=.m2'
recordIssues enabledForFailure: true, tools: [mavenConsole(), java(), javaDoc()]
recordIssues enabledForFailure: true, tool: checkStyle()
......@@ -118,10 +121,15 @@ pipeline {
}
steps {
script {
update_notify = sh(returnStdout: true, script: 'mvn versions:display-dependency-updates | grep -Pzo "(?s)The following dependencies.*\\n.* \\n"').trim()
update_notify = sh(returnStdout: true, script: 'mvn --batch-mode versions:display-dependency-updates | grep -Pzo "(?s)The following dependencies([^\\n]*\\S\\n)*[^\\n]*\\s\\n"').trim()
echo update_notify
}
rocketSend channel: 'jenkinsohsome', emoji: ':wave:' , message: "Check your dependencies in *${REPO_NAME}*. You might have updates: ${update_notify}" , rawMessage: true
script {
update_notify = sh(returnStdout: true, script: 'mvn --batch-mode versions:display-plugin-updates | grep -Pzo "(?s)The following plugin update([^\\n]*\\S\\n)*[^\\n]*\\s\\n"').trim()
echo update_notify
}
rocketSend channel: 'jenkinsohsome', emoji: ':wave:' , message: "Check your maven plugins in *${REPO_NAME}*. You might have updates: ${update_notify}" , rawMessage: true
}
post {
failure {
......
......@@ -12,7 +12,7 @@
<parent>
<groupId>org.heigit.ohsome</groupId>
<artifactId>ohsome-parent</artifactId>
<version>2.9</version>
<version>2.10</version>
</parent>
<scm>
......
  • jenkinsci/branch: The Jenkins CI build failed - Details

Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment