提交 a3517606 编写于 作者: L liuyq-617

reluctant regex

上级 6d1c8e8f
...@@ -373,11 +373,11 @@ pipeline { ...@@ -373,11 +373,11 @@ pipeline {
dir('/var/lib/jenkins/workspace/TDinternal/community'){ dir('/var/lib/jenkins/workspace/TDinternal/community'){
gitlog = sh(script: "git log -1 --pretty=%B ", returnStdout:true) gitlog = sh(script: "git log -1 --pretty=%B ", returnStdout:true)
println gitlog println gitlog
if (!(gitlog =~ /\((.*)\)/)){ if (!(gitlog =~ /\((.*?)\)/)){
autoCancelled = true autoCancelled = true
error('Aborting the build.') error('Aborting the build.')
} }
temp = (gitlog =~ /\((.*)\)/) temp = (gitlog =~ /\((.*?)\)/)
temp = temp[0].remove(1) temp = temp[0].remove(1)
scope = temp.split(",") scope = temp.split(",")
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册