my build is a 3 step process. run ant to build. transfer war to server. touch reload file.
I have transfered last two steps in groovy, using antbuilder. However, I am not able to run my existing ant script using groovy.
Usually I run it using the following command in dos prompt:
ant -Dsystem=mysystem -DsomeotherOption=true
from groovy when I try to do
"ant -Dsystem=mysystem -DsomeotherOption=true".execute()
it gives an error saying ant is not a recognized command.
How can I utilize my existing ant script in groovy?
Try and give the absolute path to the ant executable, e.g. C:\path\to\ant
You could also use Ant programmatically as shown in this User Guide: http://groovy.codehaus.org/Using+Ant+from+Groovy