Or more simply, add use the resultproperty and failonerror attributes of
<exec> to get the result code and behave appropriately.

See http://nant.sourceforge.net/nightly/latest/help/tasks/exec.html

- Tony

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Roger
Lipscombe
Sent: Friday, October 27, 2006 11:58 AM
To: nant-users@lists.sourceforge.net
Subject: Re: [NAnt-users] Perform task on error? or try/finally

Gage, Joshua SDR 2675 wrote:
> Is there some way to specify that a sub-task should run even if a
> previous task failed? Can I create another target where I execute the
> program, then in the main target delete the folder and still have Nant
> record a failed build? Is there a try/finally type of construct?
>   
NAntContrib has <trycatch>, which has nested <try>, <catch> and 
<finally> blocks.

Cheers,
Roger.


------------------------------------------------------------------------
-
Using Tomcat but need to do more? Need to support web services,
security?
Get stuff done quickly with pre-integrated technology to make your job
easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache
Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
NAnt-users mailing list
NAnt-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nant-users

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
NAnt-users mailing list
NAnt-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nant-users

Reply via email to