aspose file tools*
The moose likes Ant, Maven and Other Build Tools and the fly likes How to write ANT script to build an ear file for Struts and Ejb program Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Bookmark "How to write ANT script to build an ear file for Struts and Ejb program" Watch "How to write ANT script to build an ear file for Struts and Ejb program" New topic
Author

How to write ANT script to build an ear file for Struts and Ejb program

sumanta panda
Ranch Hand

Joined: Jun 23, 2008
Posts: 224
Dear All,

I am beginner of writting Ant script.

Can any one please give me the pointer or send me the simple ant script for how to write an ant script for making ear file for Struts and EJB based application?

Thanks for your time.

Regards,
Sumanta Panda
Martijn Verburg
author
Bartender

Joined: Jun 24, 2003
Posts: 3274
    
    5

Have you tried the ANT documentation?


Cheers, Martijn - Blog,
Twitter, PCGen, Ikasan, My The Well-Grounded Java Developer book!,
My start-up.
sumanta panda
Ranch Hand

Joined: Jun 23, 2008
Posts: 224
Dear Martijn,

Yeah i have tried after reading the ANT document.I am facing many issue.

So can please provide me the pointer or small piece of build.xml code which helps me to writting struts and EJB integrate ear file.
Martijn Verburg
author
Bartender

Joined: Jun 24, 2003
Posts: 3274
    
    5

Well what have you go so far? The struts stuff is just goes into your WAR (which in turn goes into your EAR), there are WAR and WAR tasks you can use in ant to build these...
Peter Johnson
author
Bartender

Joined: May 14, 2008
Posts: 5823
    
    7

Have you tried reading a book such as Ant in Action? I have the prior edition of the authors' book and found it invaluable.


JBoss In Action
sumanta panda
Ranch Hand

Joined: Jun 23, 2008
Posts: 224
Dear Martijn,

I have written the build.xml which is perfectly create the UserDetails.war for struts part.My doubt in the below build.xml what i need to add so that it will crate
a jar file for ejb part and both will make a ear file.


build.xml



Please suggest.
Thanks in advance.
Regards,
Sumanta
Martijn Verburg
author
Bartender

Joined: Jun 24, 2003
Posts: 3274
    
    5

You're getting there! See http://ant.apache.org/manual/CoreTasks/jar.html for the jar task... there's also an EAR task if I remember correctly...
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to write ANT script to build an ear file for Struts and Ejb program