ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "J. Matthew Pryor" <matthew_pr...@versata.com>
Subject RE: Using IF
Date Fri, 14 Sep 2001 01:06:31 GMT
Unless I missed it, I can't find an example of it in the documentation for
1.4, but I think the <equals> element of <condition> is what you want

Something like :

  <condition property="danceTypeIsSetToFunkyChicken">
      <equals arg1="${danceType}" arg2="FunkyChicken"/>
  </condition>

  <target name="doTheFunkyChicken if="danceTypeIsSetToFunkyChicken">
	<doTheFunkyChicken/>
  </target>

I haven't tested it yet, but I will

jmp


> -----Original Message-----
> From: Diane Holt [mailto:holtdl@yahoo.com]
> Sent: Thursday, September 13, 2001 5:42 PM
> To: ant-user@jakarta.apache.org
> Subject: Re: Using IF
>
>
> --- Cory Adams <cory.adams@allogis.com> wrote:
> > Could somebody please help me with regard to using if statments in Ant?
>
> As of release 1.4, you can use the <condition> task to test the value of a
> property (see the doc for examples). The if/unless attributes of <target>
> are only for testing whether a property is set/not-set.
>
> Diane
>
> =====
> (holtdl@yahoo.com)
>
>
>
> __________________________________________________
> Terrorist Attacks on U.S. - How can you help?
> Donate cash, emergency relief information
> http://dailynews.yahoo.com/fc/US/Emergency_Information/


Mime
View raw message