Title: Zip task recursively
Hi,
 
The trick is in the fileset patterns:
 
<zip zipfile="backup.zip">
        <fileset basedir=".">
        <includes name="**/*.*"/>
        </fileset>
</zip>
 
** Matches directories, and *.* matches files.
 
Cheers,
 
Duncan
----- Original Message -----
Sent: Wednesday, November 12, 2003 10:05 PM
Subject: [Nant-users] Zip task recursively

I want to recursively zip the entire source tree (all subdirectories and underneath) from NANT build script.
I couldn't find any option for that. I tried the following, but It zips only top level files. I don't want to enumerate all the directories.

Is there any way of doing it  ?

<zip zipfile="backup.zip">
        <fileset basedir=".">
        <includes name="*.*"/>
        </fileset>

</zip>

Reply via email to