从Jenkins管道中的文件运行Powershell脚本 [英] Run Powershell script from file in Jenkins pipeline
本文介绍了从Jenkins管道中的文件运行Powershell脚本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在尝试从Jenkins管道中的文件运行Powershell脚本.
I am trying to run a Powershell script from a file in a Jenkins pipeline.
我已阅读此,其中显示了如何运行powershell输入到管道中的脚本,但是我无法从文件中运行脚本.
I have read this which shows how to run powershell scripts that are entered into the pipeline, but I can't get a script to run from a file.
我尝试过:
powershell returnStatus: true, script: '-File build.ps1'
和各种组合,但无法弄清楚该怎么做.
and various combinations but can't figure out how to do this.
推荐答案
不久之后就发现了这一点,该行应已读入
Figured it out soon after, the line should have read
powershell returnStatus: true, script: '.\\build.ps1'
这篇关于从Jenkins管道中的文件运行Powershell脚本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文