ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jan.Mate...@rzf.fin-nrw.de
Subject AW: <Fail> question
Date Tue, 15 Mar 2005 10:41:38 GMT
<available>?

Jan

> -----Ursprüngliche Nachricht-----
> Von: rakesh mailgroups [mailto:rakesh.mailgroups@gmail.com]
> Gesendet am: Dienstag, 15. März 2005 11:38
> An: Ant Users List
> Betreff: <Fail> question
> 
> Hi,
> 
> I would like my build file to abort if a file does not exist.
> 
> I couldn't find a way to find out if the file exists, but I did see a
> way to check for the existence of properties (since the file is a
> property file), I did this:
> 
> <target name="checkProperties">
>         <echo>Value of password is ${sun.password}</echo>
> 	<fail unless="${sun.password}"/>
> </target>
> 
> However, here's the result:
> 
> Buildfile: C:\Projects\HelloSample\build.xml
> checkProperties:
>      [echo] Value of password is admin
> BUILD FAILED: C:\Projects\HelloSample\build.xml:29: unless=admin
> 
> It shouldn't fail since the property is set but it does.
> 
> Thanks
> 
> Rakesh
> 
> ---------------------------------------------------------------------
> 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