<target name="x" depends="do-a, do-b" />

<target name="do-a" if="auto-deploy">
        <javac dest="${dir.deploy.auto}" ... />
</target>

<target name="do-b" unless="auto-deploy">
        <javac dest="${dir.build}" ... />
</target>

On Tue, 2004-12-14 at 20:25, Charles Daniels wrote:
> You can use ant-contrib tasks: http://ant-contrib.sourceforge.net/
> (click on the "Other tasks" link to see the list of available tasks).
> Alternatively, you can use Maven (http://maven.apache.org) instead of
> Ant. 
> 
> > -----Original Message-----
> > From: Laran Evans [mailto:[EMAIL PROTECTED] 
> > Sent: Tuesday, December 14, 2004 12:17 PM
> > To: Ant User Mailing List
> > Subject: Conditional processing
> > 
> > How would I do something like:
> > 
> > <target name="x">
> >    <if test="true == ${auto-deploy}">
> >      <javac dest="${dir.deploy.auto}" ... />
> >    </if>
> >    <else>
> >      <javac dest="${dir.build}" ... />
> >    </else>
> > </target>
> > 
> > ?
> > 
> > -- 
> > Laran Evans - Cornell University
> > p: (607) 255-6864 f: (607) 255-0327
> > 
> > 
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> > 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to