Return-Path: Delivered-To: apmail-ant-user-archive@ant.apache.org Received: (qmail 77749 invoked by uid 500); 27 Jun 2003 13:22:31 -0000 Mailing-List: contact user-help@ant.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Ant Users List" Reply-To: "Ant Users List" Delivered-To: mailing list user@ant.apache.org Received: (qmail 77733 invoked from network); 27 Jun 2003 13:22:30 -0000 Received: from unknown (HELO bodewig.bost.de) (62.96.16.111) by daedalus.apache.org with SMTP; 27 Jun 2003 13:22:30 -0000 Received: (from bodewig@localhost) by bodewig.bost.de (8.11.6/8.11.6) id h5RDMUW06493; Fri, 27 Jun 2003 15:22:30 +0200 X-Authentication-Warning: bodewig.bost.de: bodewig set sender to bodewig@apache.org using -f To: user@ant.apache.org Subject: Re: deleting specific directories... References: From: Stefan Bodewig Date: 27 Jun 2003 15:22:30 +0200 In-Reply-To: Message-ID: Lines: 25 User-Agent: Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.4 (Portable Code) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N On Fri, 27 Jun 2003, David McTavish wrote: > Perhaps you could use the ForEach task from ant-contrib and iterate > through each file and call a target that will delete the parent. Yes, easily - and Jan already provided that solution IIRC, but the original requester didn't like it, it seemed. This has one caveat, though. Say I want to delete all directories that contain a file named foo and I have a structure like this level1/ | ----> foo | ----> level2/ | ---------> foo both level1 and level2 will be matched, but the way Ant works, will invoke the target for level1 before it invokes it for level2 - ending up trying to delete a directory that's no longer preset (OK, quiet="true" should help here). Stefan --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional commands, e-mail: user-help@ant.apache.org