Suppose I have a block of Gant code:
target(echo:"test"){
ant.echo(message:"hi")
}
setDefaultTarget("echo")
This is usually run from a command line.
How could I place the block in a Grails controller and run it from there?
Suppose I have a block of Gant code:
target(echo:"test"){
ant.echo(message:"hi")
}
setDefaultTarget("echo")
This is usually run from a command line.
How could I place the block in a Grails controller and run it from there?
You can use AntBuilder for this:
class FooController {
def index = {
def ant = new AntBuilder()
ant.echo(message:"hi")
}
}