ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <>
Subject Re: Is the a traditional "if" statement in Ant?
Date Thu, 03 Jan 2002 19:50:26 GMT
On Wed, 2 Jan 2002, Cornellious Mann <> wrote:

> I can't find any task that looks like a traditional
> "if" statement.  I did see IF and UNLESS on TARGET,
> but thet don't appear to care about values.  They only
> care if a property exists or not.


An <if> task that would ship with Ant has been ruled out by the
committers far more often than I can count.

Starting with 1.4 there is <condition> that will set properties based
on a couple of possible criteria, including the value of another
property.  This task combined with if/unless on target will give you
almost all the power an <if> task would give you.

<if> tasks have been written and you will find some in the archives,
the ant-contrib project at SourceForge will get one next week, which
is basically the same I've sent to ant-dev a few months ago.  


To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message