我有一个find命令,需要在我的Jenkins groovy脚本中运行,但是该命令在管道中运行时会被截断
实际命令:
dir ("${Hostname}") {
sh 'find . -path ./Code/ui.tests/codecept/output -prune -o -exec rm -rf {} + 2> /dev/null'
}
但是日志显示以下输出,并且管道失败
[Pipeline] dir
14:52:46 Running in /home/jenkins/workspace/ui-test-slave-6txbt
[Pipeline] {
[Pipeline] sh
14:52:47 + find . -path ./Code/ui.tests/codecept/output -prune -o - exec rm -rf {} +
[Pipeline] }
[Pipeline] // dir
[Pipeline] }
[Pipeline] // node
Terminated
[Pipeline] }