ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Reilly <peter.kitt.rei...@gmail.com>
Subject Re: antcontrib settings
Date Tue, 01 Mar 2011 12:13:59 GMT
You have not passed in the classpath to the taskdef.
You need to do something like:
 <taskdef classname="net.sf.antcontrib.logic.For" name="for">
  <classpath>
     <pathelement location="lib/ant-contrib-1.0b3.jar"/>
   </classpath>

</taskdef>

On Tue, Mar 1, 2011 at 11:40 AM, Ajitesh <ajitesh_p@yahoo.com> wrote:
> hi
> I am trying to use the FOR loop present in antcontrib jar file - ant-contrib-
> 1.0b3.jar in my build.xml;
> but getting below error while running the
>
> D:\buildFRIDAY>ant
>
> Buildfile: D:\buildFRIDAY\build.xml
>
>
>
>
> BUILD FAILED
>
> D:\buildFRIDAY\build.xml:5: taskdef class net.sf.antcontrib.logic.For cannot be
>
> found using the classloader AntClassLoader
>
>
>
> MY Build.xml file is as below:-
>
> <project name="ObieeBuild" default="init" basedir=".">
>    <description>
>        obiee copy files build file
>    </description>
>  <taskdef classname="net.sf.antcontrib.logic.For" name="for"/>
>   <classpath>
>      <pathelement path="${classpath}"/>
>      <pathelement location="lib/ant-contrib-1.0b3.jar"/>
>    </classpath>
>
>  <!-- set global properties for this build -->
>  <property name="test"  location="test"/>
>
>  <target name="init" description="copying obiee files" >
>  <echo message="The first five letters of the alphabet are:"/>
> <for list="a,b,c,d,e" param="letter">
>  <sequential>
>    <echo>Letter @{letter}</echo>
>  </sequential>
> </for>
>  </target>
> </project>
>
> thanks
> Ajitesh
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
> For additional commands, e-mail: dev-help@ant.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message