Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/ant/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Ant 格式错误的集合错误_Ant_Iis 7_Appcmd - Fatal编程技术网

Ant 格式错误的集合错误

Ant 格式错误的集合错误,ant,iis-7,appcmd,Ant,Iis 7,Appcmd,从我在这里报道的第一期开始: 我正在尝试运行IIS配置的第二部分 <exec executable="cmd.exe" dir="C:/Windows/System32/inetsrv" failonerror="true"> <arg line="/c appcmd set config /section:handlers /[name=&apos;ExtensionlessUrlHandler-Integrated- 4.0&am

从我在这里报道的第一期开始:

我正在尝试运行IIS配置的第二部分

  <exec executable="cmd.exe" dir="C:/Windows/System32/inetsrv" 
    failonerror="true">
    <arg line="/c appcmd set config /section:handlers 
 /[name=&apos;ExtensionlessUrlHandler-Integrated-
    4.0&apos;].verb:GET,POST,PUT,DELETE,OPTIONS,CONNECT"/>
    </exec>
快速更新: 我试过使用dbl引号,但没有成功。我做了更多的挖掘,问题是单引号正在被删除。 如果我在dos提示符中运行cmd行而不使用单引号,它将以同样的方式失败。 命令行:

appcmd set config /section:handlers  /[name='ExtensionlessUrlHandler-
Integrated-4.0'].verb:GET
Ant脚本(调试)输出


看看这是否有帮助-我已经做了更多的挖掘,并且出于某种原因(见上文)删除了单引号好的,修复了它!引号放错了:)
appcmd set config /section:handlers  /[name='ExtensionlessUrlHandler-
Integrated-4.0'].verb:GET
[exec] 'appcmd'
[exec] 'set'
[exec] 'config'
[exec] '/section:handlers'
[exec] '/[name=ExtensionlessUrlHandler-Integrated-
4.0].verb:GET,POST,PUT,DELETE,OPTIONS,CONNECT'
[exec]
[exec] The ' characters around the executable and arguments are
[exec] not part of the command.
ute:Java13CommandLauncher: Executing 'cmd.exe' with arguments: