Set the pipeline name and description from Jenkinsfile
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I am trying to do a poc of jenkins pipeline as code. I am using the Github organization folder plugin to scan Github orgs and create jobs per branch. Is there a way to explicitly define the names for the pipeline jobs that get from Jenkinsfile? I also want to add some descriptions for the jobs. 回答1: You need to use currentBuild like below. The node part is important node { currentBuild.displayName = "$yournamevariable-$another" currentBuild.description = "$yourdescriptionvariable-$another" } Edit: Above one renames build where as Original