我有Windows 10,我想在Jenkins管道中使用bash为Ubuntu for windows执行Jen命令中的sh命令,但它不起作用
我的Jenkins管道中有以下阶段:
stage('sh how to') {
steps {
sh 'ls -l'
}
}
Run Code Online (Sandbox Code Playgroud)
错误消息是:
[C:\ Program Files(x86)\ Jenkins\workspace\pipelineascode]运行shell脚本无法运行程序"nohup"(在目录"C:\ Program Files(x86)\ Jenkins\workspace\pipelineascode"中):CreateProcess error = 2 ,Lefichierspécifiéestintrouvable
我尝试用更改Jenkins参数 - > shell可执行文件
C:\ WINDOWS\SYSTEM32\bash.exe
但同样的错误......
如何使用Windows 10的bash运行sh脚本?