You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by da...@remanresource.com on 2008/10/01 23:58:20 UTC

Way to simplify what is in my project class path?

Hi,

Currently I'm listing out each JAR file from a particular directory to put into my project class path.  I was wondering if there is a way to say, include every jar file from that directory.  Right now, here's what I have that I hope to simplify:

 <!-- set ant class path -->
  <path id="project.class.path">
   	<pathelement path="${basedir}/build/classes"/>   	
	<pathelement path ="${webInfDir}/lib/commons-beanutils-1.7.0.jar"/>
    <pathelement path ="${webInfDir}/lib/commons-collections-3.2.jar"/>
    <pathelement path ="${webInfDir}/lib/commons-digester-1.8.jar"/>
    <pathelement path ="${webInfDir}/lib/commons-logging-1.1.1.jar"/>
    <pathelement path ="${webInfDir}/lib/commons-fileupload-1.0.jar"/>
    <pathelement path ="${webInfDir}/lib/jstl.jar"/>
    <pathelement path ="${webInfDir}/lib/myfaces-api-1.2.4.jar"/>
    <pathelement path ="${webInfDir}/lib/myfaces-impl-1.2.4.jar"/>
    <pathelement path ="${webInfDir}/lib/NPSConfigDelegate.jar"/>
    <pathelement path ="${webInfDir}/lib/npsimplugin.jar"/>
	<pathelement path ="${webInfDir}/lib/standard.jar"/>
	<pathelement path ="${webInfDir}/lib/tomahawk-1.1.7.jar"/>
	<pathelement path ="${webInfDir}/lib/jdbc.jar"/>
  	<pathelement path ="${webInfDir}/lib/log4j-1.2.8.jar" />
  	<pathelement path ="${webInfDir}/classes"/>
    <pathelement path ="${classpath}"/> 
   	<!--
   	The following jars are required to compile everything
   	However they should not be in the ear file
   	-->
   	<pathelement location="${weblogic-jar-path}"/>  	
   	<pathelement location="${scp-jar-path}"/>     	
  </path>

Thanks, - Dave

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


RE: Way to simplify what is in my project class path?

Posted by Rez <po...@hotmail.com>.
    <path id="class.path">        <fileset dir="./lib">            <include name="**/*.zip"/>            <include name="**/*.jar"/>        </fileset>   </path>
 
    <target name="compile" depends="init">        <mkdir dir="build/classes"/>       <javac  destdir="build/classes" srcdir="${src}" debug="true" nowarn="true">        <classpath refid="class.path"/>       </javac>    </target>
 
--------------------> From: dave.alvarado@remanresource.com> To: user@ant.apache.org> Subject: Way to simplify what is in my project class path?> Date: Wed, 1 Oct 2008 21:58:20 +0000> > Hi,> > Currently I'm listing out each JAR file from a particular directory to put into my project class path. I was wondering if there is a way to say, include every jar file from that directory. Right now, here's what I have that I hope to simplify:> > <!-- set ant class path -->> <path id="project.class.path">> <pathelement path="${basedir}/build/classes"/> > <pathelement path ="${webInfDir}/lib/commons-beanutils-1.7.0.jar"/>> <pathelement path ="${webInfDir}/lib/commons-collections-3.2.jar"/>> <pathelement path ="${webInfDir}/lib/commons-digester-1.8.jar"/>> <pathelement path ="${webInfDir}/lib/commons-logging-1.1.1.jar"/>> <pathelement path ="${webInfDir}/lib/commons-fileupload-1.0.jar"/>> <pathelement path ="${webInfDir}/lib/jstl.jar"/>> <pathelement path ="${webInfDir}/lib/myfaces-api-1.2.4.jar"/>> <pathelement path ="${webInfDir}/lib/myfaces-impl-1.2.4.jar"/>> <pathelement path ="${webInfDir}/lib/NPSConfigDelegate.jar"/>> <pathelement path ="${webInfDir}/lib/npsimplugin.jar"/>> <pathelement path ="${webInfDir}/lib/standard.jar"/>> <pathelement path ="${webInfDir}/lib/tomahawk-1.1.7.jar"/>> <pathelement path ="${webInfDir}/lib/jdbc.jar"/>> <pathelement path ="${webInfDir}/lib/log4j-1.2.8.jar" />> <pathelement path ="${webInfDir}/classes"/>> <pathelement path ="${classpath}"/> > <!--> The following jars are required to compile everything> However they should not be in the ear file> -->> <pathelement location="${weblogic-jar-path}"/> > <pathelement location="${scp-jar-path}"/> > </path>> > Thanks, - Dave> > ---------------------------------------------------------------------> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org> For additional commands, e-mail: user-help@ant.apache.org> 
_________________________________________________________________
Get more out of the Web. Learn 10 hidden secrets of Windows Live.
http://windowslive.com/connect/post/jamiethomson.spaces.live.com-Blog-cns!550F681DAD532637!5295.entry?ocid=TXT_TAGLM_WL_domore_092008