ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Wes Moulder" <wmoul...@axyssolutions.com>
Subject RE: Specifying location in <war> task
Date Tue, 21 Nov 2000 21:50:12 GMT
My suggestion would be something like this:

	<war warfile="${tools.war}"
	     webxml="${tools.home}/${web.dir}/web.xml" >
 		<fileset dir="${tools.home}" includes="*.jsp,*.html,images/*.gif,
				  ${scripts.dir}/*.js" />
 		<lib dir="${tools.home}/lib" >
 			<exclude name="dhs31.jar" />
 			<exclude name="j2ee.jar" />
 			<exclude name="commlayer.jar" />
 		</lib>
 		<classes dir="${build.classes}" />
 	</war>
Where you have one single fileset.  This should include images in the
images/ directory, and scripts in the ${scripts.dir} directory.
--Wes

> -----Original Message-----
> From: Jay Ashworth [mailto:JAshworth@iLumin.com]
> Sent: Tuesday, November 21, 2000 2:38 PM
> To: ant-user@jakarta.apache.org
> Subject: Specifying location in <war> task
>
>
> Greetings,
>
> I'm trying to implement <war> to replace the process of
> copying files to a
> temp directory and compressing with <jar>.
>
> I'm using the following script snippet:
> 	<war warfile="${tools.war}"
> webxml="${tools.home}/${web.dir}/web.xml" >
> 		<fileset dir="${tools.home}" includes="*.jsp,*.html" />
> 		<fileset dir="${tools.home}/${images.dir}"
> includes="*.gif"
> />
> 		<fileset dir="${tools.home}/${scripts.dir}"
> includes="*.js"
> />
> 		<lib dir="${tools.home}/lib" >
> 			<exclude name="dhs31.jar" />
> 			<exclude name="j2ee.jar" />
> 			<exclude name="commlayer.jar" />
> 		</lib>
> 		<classes dir="${build.classes}" />
> 	</war>
>
> I need the 'images' (2nd fileset...) to be placed in the
> target war under an
> images/ folder (html and jsp files are needed in the root of
> the archive, so
> they're fine, however they reference all images as
> 'images/xyz.gif').  Is
> there any way to do this?  I can't see in the documentation
> how to force
> included files to a particular location in the WAR heirarchy.
>
> Thank you,
>
> Jay Ashworth
> Configuration Specialist
> iLumin Corporation
> 801-852-8800
> jashworth@ilumin.com
>


Mime
View raw message