xml - Apache ant buildfile looping -
lord of beginners here.
i'm trying make target in build.xml restarts when meets condition. i've searched high , low , can't come solution make target...well...loop. i'm stuck on , it's driving me crazy, welcomed.
edit: target want loop:
<target name="prog" description="executes program"> <parallel> <daemons> <exec executable="mch" /> </daemons> </parallel> <exec executable="calculator" inputstring="$var"> <redirector output="log.txt" /> </exec> <delete file="log.txt" /> </target> the executable creates file when closes without finishing. loop condition if file exists or not.
could use waitfor task checkevery
https://ant.apache.org/manual/tasks/waitfor.html
sounds similar example on task page
<waitfor maxwait="3" maxwaitunit="minute" checkevery="500"> <http url="http://localhost/myapp/index.html"/> </waitfor> waits 3 minutes (and checks every 500 milliseconds) web server on localhost serve specified url.
Comments
Post a Comment