In the examples/anttask directory we have provided an example
on how VAInstall and Ant can be used.
The interesting file is hello.xml which is the Ant
build file.
In order to use VAInstall with Ant you have define the task:
<taskdef name="vainstall"
classname="com.memoire.vainstall.ant.VAInstallTask"/>
The next thing to setup the properties needed for VAInstall. You can do
this by referring to a file containing the properties or explicit write
the properties in the build file:
<property file="hello.vai"/>
Now you can use the vainstall task. This is from the
example:
<vainstall>
<fileset dir="src"/>
<javalauncher scriptname="hello_withargs"
javaclass="hello"
classargs="good,example"
javamode="console"
javaargs="-mx64m"
classpath="java"
/>
<javalauncher scriptname="hello_noarg"
javaclass="hello"
classpath="java"
/>
</vainstall>
You can specify files to be included in using the fileset
type. You can use one or more fileset statements.
The attributes for the fileset statement is documented
in the Ant documentation.
You can specify scripts using the javalauncher
type. You can use one or more javalauncher statements.
The attributes for the javalauncher statement is
documented on the File list page
in this manual. The only differnce is that you have to use lower
letter attribute names.