Return-Path: Delivered-To: apmail-ant-user-archive@www.apache.org Received: (qmail 79420 invoked from network); 31 Jan 2007 21:30:10 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 31 Jan 2007 21:30:10 -0000 Received: (qmail 75199 invoked by uid 500); 31 Jan 2007 21:30:12 -0000 Delivered-To: apmail-ant-user-archive@ant.apache.org Received: (qmail 75165 invoked by uid 500); 31 Jan 2007 21:30:12 -0000 Mailing-List: contact user-help@ant.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Ant Users List" Reply-To: "Ant Users List" Delivered-To: mailing list user@ant.apache.org Received: (qmail 75154 invoked by uid 99); 31 Jan 2007 21:30:12 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 31 Jan 2007 13:30:12 -0800 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: domain of peter.kitt.reilly@gmail.com designates 66.249.92.170 as permitted sender) Received: from [66.249.92.170] (HELO ug-out-1314.google.com) (66.249.92.170) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 31 Jan 2007 13:30:03 -0800 Received: by ug-out-1314.google.com with SMTP id m3so292963ugc for ; Wed, 31 Jan 2007 13:29:41 -0800 (PST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=Qr24wkFOdSdQUxNh+ey3zvM8yt9c1Ew2YJ1xOwN4XevJYwu8+V8qEGrctCtBRE6PZjY2wKPNlvDdcaDwmiUiTBxVAIpeMkg4Awd7QMxS+I4DbsSj5BSTxlUB++G2FvkmvyhxuP0N6uQ016G/J2OflnsDyTpMuKN5UKHFavX+bRI= Received: by 10.82.162.14 with SMTP id k14mr321823bue.1170278981455; Wed, 31 Jan 2007 13:29:41 -0800 (PST) Received: by 10.82.152.11 with HTTP; Wed, 31 Jan 2007 13:29:41 -0800 (PST) Message-ID: Date: Wed, 31 Jan 2007 21:29:41 +0000 From: "Peter Reilly" To: "Ant Users List" Subject: Re: possible delete bug?? In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: X-Virus-Checked: Checked by ClamAV on apache.org 1) you are excluding "a", not "temp/a" 2) java does not expose symbolic links so the delete task does not know that "a" is a symbolic link, it thinks it is a directory and follows it. Peter On 1/31/07, Tracy Jones wrote: > Hi - I have the following target that is meant to delete all files in a > directory except for the ones in a list > > > > > > > > > > includeemptydirs="true" > > > excludes="${keepfiles}"> > > > > > > > > > > > > > > The directory temp contains sym links to directory a and b > > > > sluser@StrataLight:~/test$ ls -Rl > > .: > > total 4 > > drwxr-xr-x 2 sluser sluser 1024 Jan 24 22:09 a > > drwxr-xr-x 2 sluser sluser 1024 Jan 24 22:09 b > > drwxr-xr-x 2 sluser sluser 1024 Jan 24 22:09 c > > drwxr-xr-x 2 sluser sluser 1024 Jan 24 22:09 temp > > > > ./a: > > total 0 > > > > ./b: > > total 0 > > > > ./c: > > total 0 > > > > ./temp: > > total 0 > > lrwxrwxrwx 1 sluser sluser 4 Jan 24 22:09 a -> ../a > > lrwxrwxrwx 1 sluser sluser 4 Jan 24 22:09 b -> ../b > > > > Then I run my script, delete tries to delete the directory temp even > though it is contained in the exclusions. If I do not have sym links > inside temp, this works properly. > > > > test: > > Setting project property: keepfiles -> temp a b c d > > fileset: Setup scanner in dir /home/sluser/test with patternSet{ > includes: [*/**] excludes: [temp, a, b, c, d] } > > [delete] Deleting /home/sluser/test/temp/b > > > > BUILD FAILED > > /var/stratalight/home/sluser/test.xml:18: Unable to delete directory > /home/sluser/test/temp/b > > > > Is this a bug? Or a feature :-) > > > > Tracy > > > > > > > > > > --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional commands, e-mail: user-help@ant.apache.org