Reputation: 121
I'm trying to create a batch file that automates an annoying build process. The key part that's tripping me up is when a command starts a process that takes over input from the keyboard.
Basically, I run something along the lines of ant -f build-rmi.xml rmiregistry, which builds and runs the rmiregistry. After this is completed i need to run another build, but I can't figure out how to launch another command after the ant build is finished executing
I don't have write access to any of the ant files.
Upvotes: 3
Views: 3367
Reputation: 93
use command call , the batch script file will not stop after run ant command
call ant
Upvotes: 1
Reputation: 2481
<project name="run-both" default="runbatch"> <import file="${path_to_rmi}/build-rmi.xml"/> <target name="runbatch" depends="rmiregistry"> <exec executable="cmd"> <arg value="/c"/> <arg value="echo hello Matt"/> </exec> </target> </project>
On the command prompt
ant -f run-both.xml
Upvotes: 1