powershell运行cmd命令时出错The token ‘&&‘ is not a valid statement separator in this version.

powershell运行cmd命令,出错:

The token '&&' is not a valid statement separator in this version.

先前命令:

cmd.exe /c cmd1 && cmd2

之后成功运行,需要“”来隔离开,命令修改为:

cmd.exe /c “cmd1 && cmd2”

你可能感兴趣的:(Powershell,windows)