camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From zregv...@apache.org
Subject [camel] branch master updated: CAMEL-11930: deploy only if build from master
Date Fri, 23 Mar 2018 08:40:41 GMT
This is an automated email from the ASF dual-hosted git repository.

zregvart pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git


The following commit(s) were added to refs/heads/master by this push:
     new 98c08e7  CAMEL-11930: deploy only if build from master
98c08e7 is described below

commit 98c08e735905b8d1ea8908996ae857c3aea46686
Author: Zoran Regvart <zregvart@apache.org>
AuthorDate: Fri Mar 23 09:36:17 2018 +0100

    CAMEL-11930: deploy only if build from master
    
    With multi branch pipeline Jenkins job, for every branch that is built
    the results are automatically deployed to ASF Maven snapshot repository.
    We should do this only for the `master` branch as it could lead to
    incompatible versions of artefacts being present in the repository.
---
 Jenkinsfile | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/Jenkinsfile b/Jenkinsfile
index 4ea8d4d..f716369 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -39,6 +39,20 @@ pipeline {
     stages {
 
         stage('Build & Deploy') {
+            when {
+                branch 'master'
+            }
+            steps {
+                sh "./mvnw $MAVEN_PARAMS -Dnoassembly -Dmaven.test.skip.exec=true clean deploy"
+            }
+        }
+
+        stage('Build') {
+            when {
+                not {
+                    branch 'master'
+                }
+            }
             steps {
                 sh "./mvnw $MAVEN_PARAMS -Dnoassembly -Dmaven.test.skip.exec=true clean deploy"
             }

-- 
To stop receiving notification emails like this one, please contact
zregvart@apache.org.

Mime
View raw message