This week's book giveaway is in the OCPJP forum.
We're giving away four copies of OCA/OCP Java SE 7 Programmer I & II Study Guide and have Kathy Sierra & Bert Bates on-line!
See this thread for details.
The moose likes Ant, Maven and Other Build Tools and the fly likes WSAD and Ant Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA/OCP Java SE 7 Programmer I & II Study Guide this week in the OCPJP forum!
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Bookmark "WSAD and Ant" Watch "WSAD and Ant" New topic
Author

WSAD and Ant

Jay Damon
Ranch Hand

Joined: Jul 31, 2001
Posts: 282
I use the Ant plug-in in WSAD v4.0.3 to perform our nightly builds. I have a build script file using WSAD-specific Ant tasks to refresh, build, deploy, etc. Due to a bug in the WSAD-specific tasks, they cannot be executed in dependent script files in v4.0.3
Each of the WSAD-specific tasks takes the project name and type and performs the appropriate Ant task accordingly. As a result, my project names are in a half-dozen places in the build script file. I would like to make my build script generic enough so they can be used company-wide but I am unable to figure out how to isolate project names and types so someone can take my build script file, change it in a single place, and run it.
I have experimented with JavaScript and, while this seemed like the solution, the immutability of properties kept me from achieving the desired result.
Perhaps the author(s) of Ant Developer’s Handbook have some suggestions? Does your book address the use of JavaScript in Ant build scripts?
Kirk Pepperdine
Author
Ranch Hand

Joined: Jan 17, 2001
Posts: 71
No, we don't cover java script. What we do cover is the use of properties files. If you can isolate the properties to a properties file, then you can at least coral (excuse the pun) the changes to a single location. You can read in the properties file using the property task and the file attribute.
HTH,
Kirk


Author of <a href="http://www.amazon.com/exec/obidos/ASIN/0672324261/ref=jranch-20" target="_blank" rel="nofollow">Ant Developer's Handbook</a>
Jay Damon
Ranch Hand

Joined: Jul 31, 2001
Posts: 282
I was asked in a private message where to find WSAD-specific Ant tasks. I will post the links here so that they are available to all:
Using Ant with WebSphere Studio Application Developer
is the 1st of 3 articles by Barry Searle on using Ant with WSAD v4. A link to the Ant tasks he has created is included in the article.
Ant tasks provided by the platform is a link to a page that describes some previously WSAD-specific tasks that have been incorporated into Eclipse 2.0 (WSAD v5). I believe Barry Searle has updated his Ant tasks for WSAD v5 but I'm not sure if he has made them available yet.
For the latest information regarding Ant and WSAD, I suggest you watch for articles posted in the WebSphere Developer Domain Library. It is the best source of information for WSAD and all things WebSphere.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: WSAD and Ant