ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Duffey, Kevin" <KDuf...@marketron.com>
Subject Deleting all nested dirs/files except one?
Date Wed, 04 Jun 2003 17:04:45 GMT
Hi,

I am trying to get my script to do a clean build. The dir structure of our project is like:

/bin
/dist
/src
/lib
/doc
/scripts


I put our build scripts in the /scripts folder. So I want to delete ALL folders except the
/scripts folder. In fact, I want to delete the entire base dir of the project, all sub folders,
files, etc, except the /scripts dir and the /doc dir. When this is done, I then grab the latest
out of CVS. How can I do this?

I have tried:

<delete includeEmptyDirs="true" dir="${PROJECT_HOME}" defaultexcludes="false">
	<fileset dir="${PROJECT_HOME}">
		<exclude name="scripts/**"/>
		<exclude name="doc/**"/>
	</fileset>
</delete>

This works in that it deletes ALL files. But it doesn't delete the dirs. I am hoping to avoid
having to specify every single dir one at a time in individual delete tasks.

Also, what is the name of the folder where ya'll keep your build scripts? I named it /scripts,
seemed appropriate enough. I have seen some name it /build. What is the norm for this name?

Thanks.
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.483 / Virus Database: 279 - Release Date: 5/19/2003
 


***********************************************************
The information contained in this e-mail message may be 
confidential and  protected from disclosure. If you are 
not the intended recipient, any dissemination, distribution
or copying is strictly prohibited. If you think that you 
have received this e-mail message in error,
please e-mail the sender at exchangeadmins@marketron.com
***********************************************************

Mime
View raw message