<target name="init">
<!-- normal properties, <tstamp> ... -->
<property name="os" value="" />
<antcall target="init${os}"/>
</target>
<target name="initwindows"/>
<target name="initunix"/>
...
Just a suggestion ...
But maybe <pathconvert> would help you.
Jan Matèrne
> -----Ursprüngliche Nachricht-----
> Von: Ionel Gardais [mailto:ionel.gardais@geomath.fr]
> Gesendet am: Dienstag, 25. März 2003 12:40
> An: user@ant.apache.org
> Betreff: conditional property setup
>
> Hi,
>
> I'm trying to setup a bulid file that runs on both Unix and Windows.
>
> for this, some properties need to be set in the correct way (unix in
> absolute path and windows in relative)
>
> I change my plain <property .../> tags to <condition ...>
> tags but when
> I launch ant, it complains about the missplacing of the condition tag.
>
> How to set properties according to the os family value ?
>
> thanks,
> ionel
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
>
|