Home
Overview
Available Tasks (General)
projectBuild
compileWorkspace
getJavacErrorCount
getProjectData
setDebugInfo
Available Tasks (J2EE)
AppClientExport
EARExport
UtilJar
WARExport
Available Tasks (EJB enabled tools only)
AccessBeanRegeneration
EJBDeploy
EJBExport
Overview

You can use the Run ANT option within WSAD to check your build environment or use the command line batch file provided for repetitive builds.  For detailed explanations see the series of articles
"using Ant with WebSphere Studio Application Developer" (Part-2 focuses on the ANT Task specifics for J2EE operations).

In the root of this plugin is a sample batch file called runANT.bat, which will run a "headless" workspace and run a specified ANT script file (example.xml). The ANT script file must be a fully qualified name. 

Edit the runANT.bat file and change the variables to the correct location for your WSAD installation, This file needs to be updated to run this plugin from the command line.

If you do not specify a build file, runANT will prompt you when you execute the file. You can then select ANT, list all projects, and quit. When you specify the build file, it is relative to the project so you must enter project name\buildfile name. Note that this is case sensitive.

After you list the projects available, select the ANT option and type in your build filename. You then need to quit manually when the script is finished or specify another project. The projects must all be relative to the same workspace.

Also included is an example.xml file which shows how to use some of the tasks provided through ANT. Please refer to example.xml and runANT.bat for more information. Note that the tasks themselves are case sensitive but the parameters available on each task are not.

Hints and Tips

1. When creating an ANT Script, logical order is important. For example, if you are exporting an Enterprise Application containing EJBs, you should generate deployed code for your EJB before exporting. 

Your xml should look like this: 

<!-- Run ejbDeploy on the EJB project in an EAR file --> 
<ejbDeploy EJBProject="MinibankEJB" IgnoreErrors="true"/> 
<!-- Export the Application project as an EAR file --> 
<earExport EARProjectName="MinibankExample" EARExportFile="f:\temp\sample.ear" 
ExportSource="true"/> 
2. If you are using the runAnt.bat file to do multiple builds, ensure you change the name of the output in your xml file. If your current build is incomplete or fails in any way, you still have the previous build to work from.