You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by sj...@apache.org on 2022/12/03 13:59:28 UTC
[maven-site] branch clean-workspace created (now f28d3dc9)
This is an automated email from the ASF dual-hosted git repository.
sjaranowski pushed a change to branch clean-workspace
in repository https://gitbox.apache.org/repos/asf/maven-site.git
at f28d3dc9 Clean workspace before build
This branch includes the following new commits:
new f28d3dc9 Clean workspace before build
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
[maven-site] 01/01: Clean workspace before build
Posted by sj...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
sjaranowski pushed a commit to branch clean-workspace
in repository https://gitbox.apache.org/repos/asf/maven-site.git
commit f28d3dc9a46e96bdc601b88c8241f36a2c729283
Author: Slawomir Jaranowski <s....@gmail.com>
AuthorDate: Sat Dec 3 14:58:45 2022 +0100
Clean workspace before build
Old workspace can contain corrupted git data
or contain data created by another git version
---
Jenkinsfile | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/Jenkinsfile b/Jenkinsfile
index 1a807fe3..efa8d145 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -27,6 +27,11 @@
not { branch 'master' }
}
steps {
+ // Clean before build
+ cleanWs()
+ // We need to explicitly checkout from SCM here
+ checkout scm
+ // build with Maven
withMaven(jdk:'jdk_17_latest', maven:'maven_3_latest', mavenLocalRepo:'.repository', options: [
artifactsPublisher(disabled: true),
junitPublisher(disabled: true),
@@ -42,6 +47,11 @@
branch 'master'
}
steps {
+ // Clean before build
+ cleanWs()
+ // We need to explicitly checkout from SCM here
+ checkout scm
+ // build with Maven
withMaven(jdk:'jdk_17_latest', maven:'maven_3_latest', mavenLocalRepo:'.repository', options: [
artifactsPublisher(disabled: true),
junitPublisher(disabled: true),
@@ -65,5 +75,7 @@
//timestamps()
disableConcurrentBuilds()
ansiColor('xterm')
+ // This is required if you want to clean before build
+ skipDefaultCheckout(true)
}
}