ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jan.Mate...@rzf.fin-nrw.de
Subject RE: <uptodate/>
Date Thu, 13 Nov 2003 14:38:17 GMT
Use <target unless="help-current">

Targets if and unless attributes require the NAME of a property.


Jan


> -----Original Message-----
> From: Sven Kuenzler [mailto:svenk@despammed.com]
> Sent: Thursday, November 13, 2003 3:22 PM
> To: user@ant.apache.org
> Subject: <uptodate/>
> 
> 
> How is the uptodate Task supposed to be working?
> 
>     <target name="checkhelp" depends="prepare">
>       <uptodate property="help-current"
>                 srcfile="${resource.dir}/doc/handbuch.xml"
>                 targetfile="${build.dir}/web/base/help/index.html">
>       </uptodate>
>     </target>
> 
>     <target name="help" depends="checkhelp,helpfiles"/>
> 
>     <target name="helpfiles" unless="${help-current}">
>        <echo message="${help-current}"/>
>     </target>
> 
> 
> Calling "ant help" gives "true" or "${help-current}" as output, 
> depending on whether the srcfile is newer or older than the target. 
> However, I would have hoped that the helpfiles task is not 
> called at all 
> when the target is up to date.
> 
> Did I miss anything?
> 
> Ant version is 1.5(.3)
> 
> 	Thanks, Sven
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
> 

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message