ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Brown, Carlton" <Carlton.Br...@compucredit.com>
Subject RE: AW: Copying Folder
Date Mon, 22 Dec 2008 14:27:06 GMT
It seems to me that you need to use the type selector.

<copy todir="${build.dir}">
 	<fileset dir="${basedir}">
		<include name="*"/>
		<type type="file"/>
	</fileset>
</copy>

http://ant.apache.org/manual/CoreTypes/selectors.html 

This will build a fileset that contains files in ${basedir} but no folders under basedir.


-----Original Message-----
From: blazingwolf7 [mailto:blazingwolf7@gmail.com] 
Sent: Monday, December 22, 2008 4:12 AM
To: user@ant.apache.org
Subject: Re: AW: Copying Folder


Not really...I just want to copy the files from the root directory But the root directory
will have folders as well. Now the problem I faced is how to filter out all the folders so
that it only copy the files from the root directory


Rebhan, Gilbert wrote:
> 
> 
> 
> -----Urspr√ľngliche Nachricht-----
> Von: blazingwolf7 [mailto:blazingwolf7@gmail.com]
> Gesendet: Montag, 22. Dezember 2008 09:53
> An: user@ant.apache.org
> Betreff: Re: Copying Folder
> 
> /*
> Hmm...there are .txt and other files inside there..
> There are folders as well. I want to ignore all folders and copy the 
> rest of the files But just keep failing to do that. It copy everything 
> */
> 
> i think you want to recursive copy, but only the files without 
> preserving the directory structure !?
> 
> look at the flatten attribute from copy task or use a flattenmapper
> 
> Regards, Gilbert
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional 
> commands, e-mail: user-help@ant.apache.org
> 
> 
> 

--
View this message in context: http://www.nabble.com/Copying-Folder-tp21124245p21124700.html
Sent from the Ant - Users mailing list archive at Nabble.com.


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


-----------------------------------------
====================================================
This message contains PRIVILEGED and CONFIDENTIAL
information that is intended only for use by the 
named recipient. If you are not the named recipient,
any disclosure, dissemination, or action based on 
the contents of this message is prohibited. In such
case please notify us and destroy and delete all 
copies of this transmission.  Thank you.
====================================================

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


Mime
View raw message