当我在构建机器的命令行上运行它时,它工作得很好。但是当在构建脚本中运行时,我得到一个“退出代码3”。
C:\Program Files\Wavelink\Avalanche\PackageBuilder>.\jresdk\bin\java -classpath
"WLUtil.jar;WLPackageBuilder.jar" com.wavelink.buildpkg.AvalanchePackageBuilder
/build PackageName
当我尝试使用ms build运行它时,这是我的语句:
<PropertyGroup>
<!--Working directory of the Package Builder Call-->
<PkgBldWorkingDir>"C:\Program Files\Wavelink\Avalanche\PackageBuilder"</PkgBldWorkingDir>
<!--Command line to run to make Package builder "go"-->
<PkgBldRun>.\jresdk\bin\java" -classpath "WLUtil.jar;WLPackageBuilder.jar" com.wavelink.buildpkg.AvalanchePackageBuilder</PkgBldRun>
</PropertyGroup>
<!--Run package builder command line to update the Ava File.-->
<Exec ContinueOnError="true" WorkingDirectory="$(PackageBuilderWorkingDir)"
Command="$(PkgBldRun) /build PackageName"/>
正如我上面所说,这个“退出代码3”。这是完整输出:
Task "Exec"
Command:
.\jresdk\bin\java -classpath "WLUtil.jar;WLPackageBuilder.jar" com.wavelink.buildpkg.AvalanchePackageBuilder /build PackageName
The system cannot find the path specified.
MSBUILD : warning MSB3073: The command ".\jresdk\bin\java -classpath "WLUtil.jar;WLPackageBuilder.jar" com.wavelink.buildpkg.AvalanchePackageBuilder /build PackageName" exited with code 3.
The previous error was converted to a warning because the task was called with ContinueOnError=true.
Build continuing because "ContinueOnError" on the task "Exec" is set to "true".
Done executing task "Exec" -- FAILED.
它说它找不到文件(谁知道是什么文件)。
关于如何在MS Build中运行命令行操作,有什么想法吗?