Properties in Ant are immutable - once set their value cant be change. So
the
order is:
- specify on startup via -Dname=value
- order of load/definition in the buildfile
You can override that property value via nested tag of <ant>/<antcall>.
But I�m not sure what you want to do ... usually you do something like
<target name="main" depends="tar-all"/>
<target name="tar-all">
<property name="tar.name" value="tar.default"/>
<tar .../>
</target>
Then you can call
ant main -Dtar.name=anotherName.tar
--> anotherName.tar
or
ant main
--> tar.default
Jan
> -----Urspr�ngliche Nachricht-----
> Von: Kasparek, Bernadette [mailto:[EMAIL PROTECTED]
> Gesendet am: Freitag, 18. Februar 2005 13:37
> An: 'Ant Users List'
> Betreff: Rename a property value
>
> Hi everybody,
>
> I've a problem. I want to define a property which I want to
> rename in the
> Main-Target, so that I can use it with different values.
>
> In detail I have the following code:
>
> <property name="tar.name" value="tar.default"/>
>
> <target name="main>
> <property name="tar.name" value="new"/>
> <antcall target="tar-all"/> <-- here I will use the property
> </target>
>
> My problem is, that it always take the first value. Is there
> a way how I can
> rename the value?
>
> Thanks,
>
> Bernadette Kasparek
>