Hi
use the if/unless attribute of <target> so you can create two targets where
one is accessed if the property is set and the other is accessed if the
property is not set. Like the following hack
<project name="Hugo" default="param_available" basedir=".">
<target name="param_available" if="param" depends="param_notavailable">
<echo message="param set value=${param}"/>
</target>
<target name="param_notavailable" unless="param">
<echo message="param notset"/>
</target>
</project>
This xml syntax should make the following output
if param is set -> param set value= xxx
and if not -> param is not set
Yours
Stefan S
----- Original Message -----
From: "Marco Struck" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, December 12, 2000 9:08 AM
Subject: check of properties
> hi folk,
>
> i would like to ensure that a property has been set - what is the rigtht
way
> ?
>
> <!-- call with: ant param -Dparam=test -->
> <target name="param">
> <!-- ensuring that param has been set -->
> <echo message="param=${param}" />
> </target>
>
>