I want to import multiple ant builds in Gradle. I tried using the below piece of code, it doesn’t work for me. it always loads the first ant script.
ant.importBuild(’/Project1/build.xml’) { target -> ‘antbefore-’ + target }
ant.importBuild(’/Project2/build.xml’) { target -> ‘antlater-’ + target }
task firstTask{
dependsOn ‘antbefore-mytarget’
}
task secondTask{
dependsOn ‘antlater-mytarget’
}