The source and binary distributions can be downloaded from http://sourceforge.net/projects/clearantlib
You can either build the ClearCase antlib from the source or
copy the pre-built jar file dist/clearantlib.jar into
your current Apache Ant libraries directory. To automate the
installation process you can execute the following on Windows:
>set ANT_HOME=C:\apache-ant-1.6.5
>ant install or the following on Linux/Unix: >export ANT_HOME=/opt/apache-ant-1.6.5
>ant install changing the definition of ANT_HOME to
where you have installed Apache Ant.
Once you have installed the antlib to use it in your Ant
build scripts you need to reference its XML namespace as follows: <project name="test" default="main" xmlns:ca="antlib:net.sourceforge.clearantlib">
<target name="main">
<ca:ccexec failonerror="true">
<arg value="checkout"/>
<arg value="-nc"/>
<arg value="foo.java"/>
</ca:ccexec>
</target>
</project> For more examples see the individual tasks or
this example Apache Ant build.xml file.
|