You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@uima.apache.org by re...@apache.org on 2021/01/25 16:03:25 UTC

[uima-build-resources] branch UIMA-6307-Centralize-Jenkins-pipelines created (now bd04da4)

This is an automated email from the ASF dual-hosted git repository.

rec pushed a change to branch UIMA-6307-Centralize-Jenkins-pipelines
in repository https://gitbox.apache.org/repos/asf/uima-build-resources.git.


      at bd04da4  [UIMA-6307] Centralize Jenkins pipelines

This branch includes the following new commits:

     new bd04da4  [UIMA-6307] Centralize Jenkins pipelines

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.



[uima-build-resources] 01/01: [UIMA-6307] Centralize Jenkins pipelines

Posted by re...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rec pushed a commit to branch UIMA-6307-Centralize-Jenkins-pipelines
in repository https://gitbox.apache.org/repos/asf/uima-build-resources.git

commit bd04da424e032e01429ca1ec50c10bc516f510b8
Author: Richard Eckart de Castilho <re...@apache.org>
AuthorDate: Mon Jan 25 17:03:06 2021 +0100

    [UIMA-6307] Centralize Jenkins pipelines
    
    - Use shared pipeline
---
 Jenkinsfile | 94 ++-----------------------------------------------------------
 1 file changed, 2 insertions(+), 92 deletions(-)

diff --git a/Jenkinsfile b/Jenkinsfile
index d29c7f4..74f1698 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -15,96 +15,6 @@
 // specific language governing permissions and limitations
 // under the License.
   
-pipeline {
-  agent any
-  
-  tools { 
-    maven 'maven_latest' 
-    jdk 'jdk_11_latest' 
-  }
-
-  options {
-    buildDiscarder(logRotator(
-      numToKeepStr: '25', 
-      artifactNumToKeepStr: '5'
-    ))
-    
-    // Seems not to be working reliably yet: https://issues.jenkins-ci.org/browse/JENKINS-48556
-    // timestamps()
-  }
-  
-  parameters {
-    string(
-      name: 'extraMavenArguments',
-      defaultValue: "",
-      description: "Extra arguments to be passed to maven (for testing)")
-  }
-
-  stages {
-    // Display information about the build environemnt. This can be useful for debugging
-    // build issues.
-    stage("Build info") {
-      steps {
-        echo '=== Environment variables ==='
-        script {
-          if (isUnix()) {
-            sh 'printenv'
-          }
-          else {
-            bat 'set'
-          }
-        }
-      }
-    }
-        
-    // Perform a merge request build. This is a conditional stage executed with the GitLab
-    // sources plugin triggers a build for a merge request. To avoid conflicts with other
-    // builds, this stage should not deploy artifacts to the Maven repository server and
-    // also not install them locally.
-    stage("Pull request build") {
-      when { branch 'PR-*' }
-    
-      steps {
-        script {
-          currentBuild.description = 'Triggered by: <a href="' + CHANGE_URL + '">' + BRANCH_NAME +
-            ': ' + env.CHANGE_BRANCH + '</a> (' +  env.CHANGE_AUTHOR_DISPLAY_NAME + ')'
-        }
+@Library('uima-build-jenkins-shared-library') _
 
-        withMaven() {
-          sh script: 'mvn ' +
-            params.extraMavenArguments +
-            ' -U -Dmaven.test.failure.ignore=true clean verify'
-        }
-        
-        script {
-          def mavenConsoleIssues = scanForIssues tool: mavenConsole()
-          def javaIssues = scanForIssues tool: java()
-          def javaDocIssues = scanForIssues tool: javaDoc()
-          publishIssues issues: [mavenConsoleIssues, javaIssues, javaDocIssues]
-        }
-      }
-    }
-    
-    // Perform a SNAPSHOT build of a main branch. This stage is typically executed after a
-    // merge request has been merged. On success, it deploys the generated artifacts to the
-    // Maven repository server.
-    stage("SNAPSHOT build") {
-      when { branch pattern: "main|main-v2", comparator: "REGEXP" }
-      
-      steps {
-        withMaven() {
-          sh script: 'mvn ' +
-            params.extraMavenArguments +
-            ' -U -Dmaven.test.failure.ignore=true clean deploy'
-        }
-        
-        script {
-          def mavenConsoleIssues = scanForIssues tool: mavenConsole()
-          def javaIssues = scanForIssues tool: java()
-          def javaDocIssues = scanForIssues tool: javaDoc()
-          publishIssues issues: [mavenConsoleIssues, javaIssues, javaDocIssues]
-        }
-      }
-    }
-  }
-}
+defaultPipeline { }