You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by ja...@livemedia.com on 2000/11/08 07:52:31 UTC
just dir contents?
Sorry if this have been covered:
is there any way do <delete> the contents of a directory, files, dirs & all,
but not the dir itself?
thanks,
james@livemedia.com
RE: just dir contents?
Posted by ja...@livemedia.com.
nope. subdirectories remain.
james@livmedia.com
-----Original Message-----
From: Paul Arzul [mailto:patricka@exinet.co.za]
Sent: Wednesday, November 08, 2000 1:46 AM
To: ant-user@jakarta.apache.org
Subject: Re: <delete> just dir contents?
On 8 Nov 2000, Stefan Bodewig wrote:
: >>>>> "j" == james <ja...@livemedia.com> writes:
:
: j> Sorry if this have been covered: is there any way do <delete> the
: j> contents of a directory, files, dirs & all, but not the dir
: j> itself?
:
: Yes, use a nested fileset for that.
:
: <delete>
: <fileset dir="dir.to.clean" />
: </delete>
:
: should work
works, but if "dir.to.clean" does not exist, your build
will fail. :(
that behaviour appears to be in conflict with the silent
failure of:
<delete dir="dir.to.clean" />
- p
--
Please send email to me using plain text only. :)
Re: just dir contents?
Posted by Paul Arzul <pa...@exinet.co.za>.
On 8 Nov 2000, Stefan Bodewig wrote:
: >>>>> "j" == james <ja...@livemedia.com> writes:
:
: j> Sorry if this have been covered: is there any way do <delete> the
: j> contents of a directory, files, dirs & all, but not the dir
: j> itself?
:
: Yes, use a nested fileset for that.
:
: <delete>
: <fileset dir="dir.to.clean" />
: </delete>
:
: should work
works, but if "dir.to.clean" does not exist, your build
will fail. :(
that behaviour appears to be in conflict with the silent
failure of:
<delete dir="dir.to.clean" />
- p
--
Please send email to me using plain text only. :)
Re: just dir contents?
Posted by Stefan Bodewig <bo...@bost.de>.
>>>>> "j" == james <ja...@livemedia.com> writes:
j> Sorry if this have been covered: is there any way do <delete> the
j> contents of a directory, files, dirs & all, but not the dir
j> itself?
Yes, use a nested fileset for that.
<delete>
<fileset dir="dir.to.clean" />
</delete>
should work
Stefan