O'Reilly logo

Java Enterprise in a Nutshell, Third Edition by William Crawford, Jim Farley

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 17. Ant

Enterprise software development involves a (sometimes complex) combination of source code, configuration files, HTML pages, images, and various other assets that need to be processed, combined, and deployed in order to create a running application. In addition to compiling and running code, a number of other tasks need to be performed to manage an enterprise project: generating documentation, running tests against code, interacting with source control systems, and more.

Over the years, several tools have emerged to help manage the various repetitive tasks involved with developing software. Earlier examples include make and gnumake, command-line tools that have been used to manage building and packaging code, primarily on Unix systems. make and its variants utilize a text-based command file, a makefile, that you use to specify how various tasks (compiling code, generating executables, etc.) are to be carried out, as well as dependencies between various tasks (e.g., an executable should be generated only if all of the compiled code is up-to-date).

In Java development projects, Ant has emerged as the de facto tool of choice for these types of tasks. Integrated development environments (IDEs) typically provide build/deploy tools, but Ant supports these and other development tasks in an independent manner, separate from any specific IDE. This, along with the nearly ubiquitous support in Java IDEs for editing and exercising Ant buildfiles, has made Ant a very popular tool ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required