On Mon, 11 Feb 2002 09:14, Bevan Arps wrote:
> At 20:25 10/02/2002 +1100, Peter Donald wrote:
> >Error handling in ant sucks ...
>
> I agree 100%
As a side issue. Would everyone mind describing what they think are the worst
features of ant are? I can think of 4 things that bug me no end (error
handling is one of them) - anyone else care to generate a list? I would be
interested to here it. My list basically is
* error handling sucks
* missing selection (if) constructs (others may add missing repetition
constructs)
* PITA to create reusable build file chunks
* PITA to extend and manage extensions, dependencies and so forth
> Peters Example to explain:
> ><tbody>
> > <try>
> > <echo message="About to fail"/>
> > <fail message="Failing!"/>
> > </try>
> > <catch>
> > <echo message="the task failed but we are ignoring it"/>
> > </catch>
> > <finally>
> > <echo message="Cleaning up after myself ..."/>
> > </finally>
> ></tbody>
>
> When does the finally task get executed - before the catch or after?
after - same as in java language.
> For the first, how about this:
>
> <try>
> <echo message="About to make a mess"/>
> ...
> <finally>
> <echo message="Cleaning up mess"/>
> ....
> </finally>
> </try>
>
> For the second case, and keeping in mind that the Ant term is "fail":
>
> <try>
> <echo message="About to fail"/>
> ...
> <onFail>
> <echo message="It failed."/>
> </onFail>
> </try>
>
...
> Just my 2c - what do you think?
Interesting - I am going to play with a few build files and see what it looks
like ;)
--
Cheers,
Pete
----------------------------------------
Whatever you do will be insignificant,
but it is very important that you do it.
--Gandhi
----------------------------------------
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>