Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/jenkins/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
jenkins管道脚本中存在重复的变更日志_Jenkins_Jenkins Workflow - Fatal编程技术网

jenkins管道脚本中存在重复的变更日志

jenkins管道脚本中存在重复的变更日志,jenkins,jenkins-workflow,Jenkins,Jenkins Workflow,我正在研究如何在项目的scm中使用新的Jenkins管道插件和Jenkins文件(我们使用GIT) 作业脚本从SCM加载(“来自SCM的管道脚本”选项) 在Jenkinsfile脚本中,我执行签出scm 问题在于提交是重复的。在build目录中,有2个changelog.xml具有相同的提交,因此更改视图可能非常混乱: Summary 1. FNC71010 - Ajout des traductions au launcher (details) Commit 5a676ee1448b72f

我正在研究如何在项目的scm中使用新的Jenkins管道插件和
Jenkins文件
(我们使用GIT)

作业脚本从SCM加载(“来自SCM的管道脚本”选项) 在
Jenkinsfile
脚本中,我执行
签出scm

问题在于提交是重复的。在build目录中,有2个
changelog.xml
具有相同的提交,因此更改视图可能非常混乱:

Summary

1. FNC71010 - Ajout des traductions au launcher (details)
Commit 5a676ee1448b72f1b99227e8832b01081aa1bc6d by thierry
The file was modified   Deploy_serveur/resources/config/trad.properties

Summary

1.FNC71010 - Ajout des traductions au launcher (details)
Commit 5a676ee1448b72f1b99227e8832b01081aa1bc6d by thierry
The file was modified   Deploy_serveur/resources/config/trad.properties
在多分支管道中也会出现此问题

以下是
Jenkinsfile
内容:

我做错什么了吗

詹金斯版本:1.642.2(docker) 管道版本:1.15
Git插件:2.4.3

您是否尝试将Git插件升级到2.4.4?

如果您查看控制台,是否看到Git签出两次?是的,一次来自Jenkins作业,一次来自管道脚本。但它看起来像是(从漫长的周末回来的)。我将Git插件升级到2.4.4,并且在命令
checkout scm
上不再重复提交。太好了,然后JENKINS-29326的refix工作了。
#!groovy

node {
    stage 'initialisation'
    def repertoire = "directory"

    def pipeline
    dir(repertoire) {
        checkout scm
        pipeline = load 'pipeline.groovy'
    }
    pipeline.initialisation(repertoire)
    pipeline.build()
    pipeline.runTestsRapides()
    pipeline.copieResultats()
}