Start process with args which contains a path with blanks

前端 未结 3 1114
终归单人心
终归单人心 2021-01-08 01:35

I need to start a process from a powershell script and pass such params : -a -s f1d:\\some directory\\with blanks in a path\\file.iss to do that, I write the folowing code :

3条回答
  •  情话喂你
    2021-01-08 02:14

    I think you can use Start-Process:

    Start-Process -FilePath $setupFilePath -ArgumentList '-a','-s','-f1"d:\some directory\with blanks in a path\fileVCCS.iss"' |
        Wait-Process
    

提交回复
热议问题