问题描述
我有一个用于卸载产品的 powershell 脚本。但是作为我在 ansible playbook 中调用的 powershell 脚本的一部分,它在以下位置进行语法检查时会引发错误:
echo $("Something didn't go quite right,here is the exit code from msiexec:" + $uexitCode); exit
如果我删除这段代码,剧本编译得很好,也能很好地执行。 uexitCode 有这样的东西
$umsiparams = $("/passive /norestart /x $productCode /log " + $ulog)
$uexitCode = (exit $umsiparams -Wait -Passthru).ExitCode
$ulog = $($global:temppath + "\uninstall.log")
做语法检查时的错误是
ERROR! Failed at splitting arguments,either an unbalanced jinja2 block or quotes:
如果我删除那个 echo 语句,它就可以正常工作。知道可以做什么吗?
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)