aspose file tools*
The moose likes Ant, Maven and Other Build Tools and the fly likes new to ANT Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Bookmark "new to ANT" Watch "new to ANT" New topic
Author

new to ANT

Gannarapu Rajesh
Greenhorn

Joined: Mar 03, 2005
Posts: 24
Hi,
I am new to ANT.
I want to learn ANT.
suggest the best way to learn.
is there any nice tutorial for ant?

Thanks in advance,
Rajesh Gannarapu
Paul Sturrock
Bartender

Joined: Apr 14, 2004
Posts: 10336

The easiest way I think is to look at an example build file with the Ant docs to hand. Look an an open source project (just grab something simple from Sourceforge) - most will use Ant and will include the build file. Small build files are relatively readable, even without much Ant knowledge. (Watch out for big projects like JBoss - projects like these tend to have expanded way beyond the limitations of Ant and use other products inc conjunction with it, or have defined their own custom tasks)

The most important thing to remember with Ant is to understand what you are trying to achieve with a build file. If you have a clear understanding of the steps in your build process, then translating these to an Ant build file is relatively trivial. If you don't have a clear understanding of the steps in your build process, sort this out before going anywhere near Ant.

There is also an Ant debugger available as an Eclipse plugin. This can be very useful to track what the more complex build files do.


JavaRanch FAQ HowToAskQuestionsOnJavaRanch
Roseanne Zhang
Ranch Hand

Joined: Nov 14, 2000
Posts: 1953
I have an "hello world" ant build file here, which might help.

Also many FAQs with some suggestions for ant beginners.

http://bobcat.webappcabaret.net/javachina/faq/ant_01.htm
Hemant Agarwal
Ranch Hand

Joined: Nov 21, 2005
Posts: 138
I am also new to Ant.
I don't know why there is a tool like 'ANT'?
We can build our files by compiling the files manually?
What is the benefit of ANT?

Thanks

Pratik Lohia
Ranch Hand

Joined: May 05, 2005
Posts: 88
ANT does all these things by itself. All you need to do is script it once to tell what needs to be done. Thereafter ... till eternity ANT will automatically do all the tasks for you... till you tell it not to do . ANT, just does not compile files, but also does a lot more things like running external utilities, building jars and ears, firing SQL queries, deploying and starting applications, sending mails and a lot more. So an entire cycle of building to testing to reporting can be performed with ANT once the code has been checked in with just one command that invokes the ANT script.
Hemant Agarwal
Ranch Hand

Joined: Nov 21, 2005
Posts: 138
Hi Pratik,
Plz give me links for that

Thanks
Pratik Lohia
Ranch Hand

Joined: May 05, 2005
Posts: 88
http://ant.apache.org/

Check out the manual here...
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: new to ANT