简体   繁体   English

Jenkins Pipeline忽略了git checkout的exludeMessage选项

[英]Jenkins Pipeline ignores exludeMessage Option for git checkout

My jenkins pipeline checks out the GIT repository in the first stage, there fore I'm using 我的jenkins管道在第一阶段检查了GIT存储库,因此我正在使用它

checkout([$class: 'GitSCM', branches: [[name: '*/master']], doGenerateSubmoduleConfigurations: false, extensions: [[$class: 'MessageExclusion', excludedMessage: '.*\\[Gradle-Release-Plugin\\].*'], [$class: 'LocalBranch', localBranch: 'master']], submoduleCfg: [], userRemoteConfigs: [[credentialsId: '48b64fd8-f0c8-4bcd-91e8-58f763e9be0c', url: 'https://bitbucket.org/private/private.git']]])

To prevent builds for automatic version change commit, the excludeMessage options is used. 要阻止自动版本更改提交的构建,请使用excludeMessage选项。 Nevertheless Jenkins starts builds if commits occur with this pattern. 然而,如果使用此模式进行提交,Jenkins将启动构建。 The regex pattern is correct, I double checked it. 正则表达式模式是正确的,我仔细检查它。 Does somebody facing the same problem? 有人面临同样的问题吗?

That is indeed a bug whose resolution is still pending. 这确实是一个尚未解决的问题。

See issue JENKINS-36195 "Pipeline polling ignores special polling rules" . 请参阅问题JENKINS-36195“管道轮询忽略特殊轮询规则”
The same issue is seen in " JENKINS-35988 Organization job "Branch Indexing" ignores excluded regions defined in jenkinsfile " 在“ JENKINS-35988组织工作”分支索引“忽略jenkinsfile中定义的排除区域”中可以看到相同的问题

The current assessment is: 目前的评估是:

Since the git plugin doesn't read the contents of Jenkinsfile when performing polling, I'm not sure how it would honor the polling settings inside the Jenkinsfile in the repository. 由于git插件在执行轮询时不会读取Jenkinsfile的内容,因此我不确定它将如何兑现存储库中Jenkinsfile内的轮询设置。
It seems like it would be even more challenging in a repository with more than one branch, since the polling settings might differ between branches within the same repository. 在具有多个分支的存储库中,似乎更具挑战性,因为同一存储库中的分支之间的轮询设置可能不同。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM