From 224986faf2b0b254f971fd1dff3b30af3aaa4649 Mon Sep 17 00:00:00 2001 From: liuyq-617 Date: Mon, 9 Aug 2021 20:23:20 +0800 Subject: [PATCH 1/3] test[ci skip] --- Jenkinsfile | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 4838850722..a7467c002b 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -6,7 +6,7 @@ node { } def skipstage=0 - +def skipbuild=0 def abortPreviousBuilds() { def currentJobName = env.JOB_NAME def currentBuildNumber = env.BUILD_NUMBER.toInteger() @@ -125,6 +125,9 @@ pipeline { agent{label 'master'} when { changeRequest() + not { + changelog '.*\\[ci skip\\].*' + } } steps { script{ @@ -158,6 +161,7 @@ pipeline { script{ env.skipstage=sh(script:"cd ${WORKSPACE}.tes && git --no-pager diff --name-only FETCH_HEAD ${env.CHANGE_TARGET}|grep -v -E '.*md|//src//connector|Jenkinsfile|test-all.sh' || echo 0 ",returnStdout:true) + } println env.skipstage sh''' @@ -173,6 +177,9 @@ pipeline { expression { env.skipstage != 0 } + not { + changelog '.*\\[ci skip\\].*' + } } parallel { stage('python_1_s1') { From f48e0bbc1ef53bbc1a09b96e8867b540120208b9 Mon Sep 17 00:00:00 2001 From: liuyq-617 Date: Mon, 9 Aug 2021 20:28:24 +0800 Subject: [PATCH 2/3] test[ci skip] --- Jenkinsfile | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index a7467c002b..917a8f728c 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -125,9 +125,7 @@ pipeline { agent{label 'master'} when { changeRequest() - not { - changelog '.*\\[ci skip\\].*' - } + } steps { script{ @@ -161,7 +159,8 @@ pipeline { script{ env.skipstage=sh(script:"cd ${WORKSPACE}.tes && git --no-pager diff --name-only FETCH_HEAD ${env.CHANGE_TARGET}|grep -v -E '.*md|//src//connector|Jenkinsfile|test-all.sh' || echo 0 ",returnStdout:true) - + env.skipbuild=sh(script: "git log -1 --pretty=%B | fgrep -ie '[skip ci]' -e '[ci skip]'", returnStatus: true) + println env.skipbuild } println env.skipstage sh''' @@ -176,10 +175,9 @@ pipeline { changeRequest() expression { env.skipstage != 0 + env.skipbuild ==1 } - not { - changelog '.*\\[ci skip\\].*' - } + } parallel { stage('python_1_s1') { From 93da3dad3381f16a32c30f17d35e561ddba860b7 Mon Sep 17 00:00:00 2001 From: liuyq-617 Date: Mon, 9 Aug 2021 20:35:01 +0800 Subject: [PATCH 3/3] test --- .drone.yml | 6 +++++- Jenkinsfile | 3 +-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.drone.yml b/.drone.yml index b520f308ba..cbe5c03318 100644 --- a/.drone.yml +++ b/.drone.yml @@ -150,6 +150,7 @@ steps: branch: - develop - master + - 2.0 --- kind: pipeline name: build_trusty @@ -176,6 +177,7 @@ steps: branch: - develop - master + - 2.0 --- kind: pipeline name: build_xenial @@ -201,6 +203,7 @@ steps: branch: - develop - master + - 2.0 --- kind: pipeline @@ -226,6 +229,7 @@ steps: branch: - develop - master + - 2.0 --- kind: pipeline name: build_centos7 @@ -249,4 +253,4 @@ steps: branch: - develop - master - + - 2.0 \ No newline at end of file diff --git a/Jenkinsfile b/Jenkinsfile index 917a8f728c..14bc6abfbd 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -160,7 +160,7 @@ pipeline { script{ env.skipstage=sh(script:"cd ${WORKSPACE}.tes && git --no-pager diff --name-only FETCH_HEAD ${env.CHANGE_TARGET}|grep -v -E '.*md|//src//connector|Jenkinsfile|test-all.sh' || echo 0 ",returnStdout:true) env.skipbuild=sh(script: "git log -1 --pretty=%B | fgrep -ie '[skip ci]' -e '[ci skip]'", returnStatus: true) - println env.skipbuild + } println env.skipstage sh''' @@ -177,7 +177,6 @@ pipeline { env.skipstage != 0 env.skipbuild ==1 } - } parallel { stage('python_1_s1') {