Ant Integration with Groovy Add comment to Wiki View in Wiki Edit Wiki page Printable Version


Ant is the predominant build environment for Java projects. Groovy is a leading Scripting language for the JVM. The good news is that you can use them together easily and with many benefits.

(green star) Existing Ant Users (Java Projects): If you are already familiar with using Ant with a traditional build.xml file, then you can continue to do so with almost no changes. If you want you can begin to use the <groovy> Ant task to bring the full power of a scripting language to your build scripts.

(green star) Existing Ant Users (Groovy or mixed Groovy/Java Projects): If you wish to pre-compile your Groovy scripts as part of your build process (it can help catch syntactic errors earlier if you do) then you need to know about the <groovyc> Ant task. You will find it almost identical to the javac task which you are probably already familiar with.

(green star) Existing Groovy Users: You probably want to consider how you can use AntBuilder to leverage the many available Ant tasks directly in your code using a DSL-style notation. You can leverage Ant Libraries in the same way.



Results of your search request can come from various sources: the Groovy website itself, the JIRA issues, the API documentation, as well as a few other interesting Groovy-related blogs.

  By  -  pages  -  views  - last modified