The Ant Rebellion
by Kevin Dangoor
Jon Tirsen, Martin Fowler, and Bruce Eckel have all written recently about stumbling blocks that they’ve run into with Ant. The problem is that Ant is great when it does what you want, but if something doesn’t do what you need, there’s no full-fledged programming language to get the job done. So, Jon uses Ruby to control his build, Martin has started playing with Rake (a Ruby-based make), and Bruce is generating his Ant build files. Some other set of people use Maven to theoretically simplify their builds, but that’s not exactly the same as handling complex builds.
All of this might explain why Ant 1.6 appears to include the Script task. The Script task lets you use any BSF compatible language (of which there are many) to add more complex logic to your build. Scriptdef goes even farther, letting you create new Ant tasks in scripting languages.
Using those tools, you can take advantage of Ant’s relative ubiquity and the fact that people know how to run Ant, while being able to make your builds as complex as they need to be. I’d rather leave Ant in charge of my build process (making it easier to jack into things like Anthill) and script the complex parts.
I agree; the fact that Ant plays well with (and has lots of support from) the major IDEs also motivates me to stick with Ant where possible.
The script task has been around for ages….
I wasn’t trying to imply that the script task itself was new. 1.6 is the first version of ant, as far as I know, that *includes* script and scriptdef. They used to be optional.