ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sameer Singh" <sameer.si...@openwave.com>
Subject Using properties in depends attribute?
Date Mon, 27 May 2002 20:12:34 GMT
Hi,

I can't seem to set the depends attribute of a Target using a property.

It would be great to do something like

<target name="test" depends="${test.target}"/>

and then set the test.target property to whatever target you like.

------------------------------------------------------------------

I did manage to get around this however, as follows:

----------------------------------------------------------

<condition property="run.test-one">
       <and>
	       <istrue value="${junit.present}" />
	       <istrue value="${test.one}" />
       </and>
    </condition>
    <condition property="run.test-main">
       <and>
	       <istrue value="${junit.present}" />
	       <isfalse value="${test.one}" />
       </and>
</condition>


<target name="test-main" if="run.test-main"/>
<target name="test-one" if="run.test-one">
<target name="test" depends="test-main,test-one"/>

------------------------------------------------------------

seems like a "kludge" though. Maybe this can classify as a feature
request?

Regards

Sameer




--
To unsubscribe, e-mail:   <mailto:ant-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>


Mime
View raw message