Return-Path: Delivered-To: apmail-jakarta-ant-user-archive@apache.org Received: (qmail 31998 invoked from network); 15 May 2002 13:52:02 -0000 Received: from unknown (HELO nagoya.betaversion.org) (192.18.49.131) by daedalus.apache.org with SMTP; 15 May 2002 13:52:02 -0000 Received: (qmail 25855 invoked by uid 97); 15 May 2002 13:51:53 -0000 Delivered-To: qmlist-jakarta-archive-ant-user@jakarta.apache.org Received: (qmail 25815 invoked by uid 97); 15 May 2002 13:51:51 -0000 Mailing-List: contact ant-user-help@jakarta.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 ant-user@jakarta.apache.org Received: (qmail 25790 invoked by uid 98); 15 May 2002 13:51:50 -0000 X-Antivirus: nagoya (v4198 created Apr 24 2002) Message-ID: <005001c1fc17$a71da5f0$3a05000a@seagull.nl> From: "Glen Marchesani" To: "Ant Users List" References: <002201c1fc11$f70f6770$3a05000a@seagull.nl> Subject: Re: deleting a file if it does or does not exist Date: Wed, 15 May 2002 15:51:44 +0200 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4522.1200 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4522.1200 X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Hmmm... you are right. After looking, the problem was trying to delete a jar file that was in the ant class path thus it could not be deleted (though I remember that this is jvm dependent). Cleaning up my classpath and delete behaves as expected. thanks, Glen ----- Original Message ----- From: "Stefan Bodewig" To: Sent: Wednesday, May 15, 2002 3:30 PM Subject: Re: deleting a file if it does or does not exist > On Wed, 15 May 2002, Glen Marchesani wrote: > > > > > > > This only works if the file does exist if it doesn't I get an error > > Hmm, works for me > > [bodewig@bodewig tmp]$ cat b.xml > > > > > > > [bodewig@bodewig tmp]$ ant -f b.xml > Buildfile: b.xml > > b: > > BUILD SUCCESSFUL > Total time: 1 second > > and with -verbose > > b: > [delete] Could not find file /tmp/not-there to delete. > > BUILD SUCCESSFUL > > > "D:\foo\build.xml:295: Unable to delete file D:\foo\generated.jar" > > This is the message you will get if the file exists but cannot be > deleted. > > Stefan > > -- > To unsubscribe, e-mail: > For additional commands, e-mail: > > -- To unsubscribe, e-mail: For additional commands, e-mail: