I have a project that has the following directory structure.
PROJECTHOME/
build.xml
src/
bin/
lib/
deploy/
apidoc/
my.jar
dir1/
dir2/
dir3/
more dirs....
I just want to zip apidoc/, my.jar, src/. so the Zip file has the
following structure.
* my.zip
apidoc/
my.jar
src/
My build.xml includes...
---------
<target name="zip" depends="javadoc,makejar">
<zip destfile="deploy/datectool.zip">
<fileset dir="deploy/">
<exclude name="datectool.zip"/>
</fileset>
</zip>
---------
But the problem is I cannot zip src/. I tried a lot, but couldn't.
I tried <fileset dir="src/"/> but It include only the contents for src/.
It did not make src/ in the zip file.
Thanks for reading.
David Rabinowitz - 02 Feb 2004 12:38 GMT
Try <zipfileset>. See http://ant.apache.org/manual/CoreTasks/zip.html
> I have a project that has the following directory structure.
> PROJECTHOME/
[quoted text clipped - 33 lines]
>
> Thanks for reading.
Son KwonNam - 03 Feb 2004 00:45 GMT
Thanks.
I tried the following and got the result that I exactly expected!!
<zip destfile="deploy/test.zip">
<zipfileset dir="src" prefix="src"/>
<zipfileset dir="deploy/apidoc" prefix="apidoc"/>
<zipfileset dir="deploy/dist" prefix="dist"/>
</zip>
David Rabinowitz ? ?:
> Try <zipfileset>. See http://ant.apache.org/manual/CoreTasks/zip.html
>
[quoted text clipped - 35 lines]
>>
>> Thanks for reading.