Jekins sh label: Arguments to “sh” must be explicitly named

北城余情 提交于 2019-12-13 02:49:17

问题


I'm aware of Jenkins Pipeline sh display name/label

But when using

sh "echo foo", label: "my step"

I'll get the following error:

Arguments to "sh" must be explicitly named

I made sure to have Pipeline: Nodes and Processes v2.28 installed and I'm using a declarative pipeline.


回答1:


I found it out myself, it must be:

sh script: "echo foo", label: "my step"


来源:https://stackoverflow.com/questions/54787285/jekins-sh-label-arguments-to-sh-must-be-explicitly-named

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!