ANT Introduction



Need of build tool :

We know that while doing complex coding practices in the Java we sometimes do following time consuming and hectic tasks manually, such as –

  1. Compiling the Java code
  2. Packaging the binaries
  3. Deploying the binaries to the server
  4. Testing out the changes
  5. Moving or copying code from one location to another

If you really want to make your task more simpler by automating all these processes then we need to use the build tools.

Coding Efforts ANT
The above chart indicate that –

  1. On average, a developer spends 3 hours out of 10 hours of day are utilized for doing the manual tasks such as packaging,moving and compiling.
  2. If developer uses automated build tools such as Apache Ant then it will only require half an hour to complete all those manual tasks.

About Apache Ant :

  1. Ant stands for Another Neat Tool
  2. Ant was created by James Duncan Davidson. He was original author of Tomcat
  3. Ant was used to build Tomcat originally.
  4. Ant was bundled as part of Tomcat distribution
  5. Ant was created to overcome the problems and complexity associated with the make tool
  6. Ant was independent project in Apache in 2000
  7. NAnt is a .NET build tool which is used to build .NET apps

Features of Apache Ant :

  1. Ant is most used and complete Java build and Deployment tool available.
  2. Ant can handle platform specific properties such as file separators.
  3. Ant uses XML for writing the scripts which is simple and easy to understand. [ Learn XML Here ]
  4. Ant can handle and automate complicated repetitive tasks.
  5. Ant has lot of predefined tasks and creation of the new task is easy.
  6. Ant can invoked easily using command line and IDE such as Eclipse.

In the next article we will be learning the necessary steps for setting up Ant environment.