Hi,
If there are Ant tasks available you can use them in an ant { } block in
your build.gradle file, I think this is the easist and prefer it over
calling command lines manually. Also because it makes porting easier. You
can use the asPath on a dependency configuration to access the jar files for
your ant taskdef, so for example:
dependencies {
addConfiguration('jibxAnt')
addMavenRepo()
jibxAnt // add jibx dependency here
}
createTask('jibx') {
ant{
taskdef(name:'jibx', classname: ... , classpath: jibxAnt.asPath ) //
I didn't check the name
// call jibx task(s)
}
}
2009/3/17 <[email protected]>
> Hi all,
>
> I need to run some JibX binding compile while building my project. I was
> wondering which was the best practice with gradle to do so.
>
> Either using Groovy's AntBuilder
> Or calling from Gradle script a custom "java -jar jibx-bind.jar (...)"
>
> What are the pros/cons for each method ?
>
> And for both methods, how can access the jar file? Is all .gradle/cache
> folder included in the classpath, or should I use a variable. If so, is
> there a Gradle variable pointing to the cache dir?
>
> Thanks in advance
>