cmd /C needs to be quoted as a whole
To support spaces in both the command as well as its arguments cmd needs be called like this: cmd /C ""c:\a b\c.bat" "argument 1" "argument2"" ant was running cmd /C "c:\a b\c.bat" "argument 1" "argument2" which in windows causes to be preprocessed to cmd /C c:\a b\c.bat" "argument 1" "argument2 Which would make it appear as though ant was not properly quoting (which it did sort of).
This commit is contained in:
parent
6e2dc73023
commit
a80317c4b3
|
@ -32,8 +32,10 @@
|
|||
<echoxml><exec script="${script.base}"><nested/></exec></echoxml>
|
||||
<exec executable="cmd" osfamily="winnt" dir="${temp.cwd}" failonerror="${failonerror}" spawn="@{spawn}" taskname="${script.base}">
|
||||
<arg value="/c"/>
|
||||
<arg value="""/>
|
||||
<arg value="@{script}.bat"/>
|
||||
<nested/>
|
||||
<arg value="""/>
|
||||
</exec>
|
||||
|
||||
<exec executable="sh" osfamily="unix" dir="${temp.cwd}" failonerror="${failonerror}" spawn="@{spawn}" taskname="${script.base}">
|
||||
|
|
Loading…
Reference in New Issue