ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gerard Janssen <mail...@janssenenjansen.nl>
Subject Re: Copying folders
Date Wed, 12 Jan 2005 21:36:33 GMT
Hi,

You shoud propably use:

<copy todir=${Drivers}">
    <fileset dir="${VssSourcePath}\Drivers">
        <includesfile name="**/DriversList.txt"/>
    </fileset>
</copy>

The ** means, recurse into the dir structure and include the files at any 
level you find them. If you would specifically require only three levels try:

<copy todir=${Drivers}">
    <fileset dir="${VssSourcePath}\Drivers">
        <includesfile name="*/DriversList.txt"/>
        <includesfile name="*/*/DriversList.txt"/>
        <includesfile name="*/*/*/DriversList.txt"/>
    </fileset>
</copy>


Gerard

On Thursday 06 January 2005 06:06, Poonam wrote:
> Hi,
>
> I tried using filesets and selectors, but was not able to copy those
> selected 20 directories upto 3 levels. It just copied the first level
> files and empty directories.
> I used fileset as follows -
>
> <copy todir=${Drivers}">
> <fileset dir="${VssSourcePath}\Drivers">
> <includesfile name="DriversList.txt"/>
> </fileset>
> </copy>
>
> where DriversList.txt contains the folder name I am want to copy. I want
> to copy these folders completely i.e. upto n level.
>
> Regards,
> Poonam

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


Mime
View raw message