ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jan.Mate...@rzf.fin-nrw.de
Subject RE: Indirect referencing a property by the value of another prope rty
Date Tue, 09 Dec 2003 15:07:39 GMT
a) without any external
You canĀ“t

b) with <script> (needs libraries)
   propnameValue = project.getProperty("prop-name");
   project.setNewProperty("prop", propnameValue);

c) with AntContrib (external task library)
   <propertycopy name="prop" from="${prop-name}"/>


Jan
   


> -----Original Message-----
> From: Christian Mallwitz [mailto:C.Mallwitz@intershop.com]
> Sent: Tuesday, December 09, 2003 3:57 PM
> To: 'user@ant.apache.org'
> Subject: Indirect referencing a property by the value of another
> property
> 
> 
> Hi
> 
> I have a property where the value is the _name_ of another property.
> 
> How can I do something like 
> 
> <property name="prop" value="${${prop-name}}"/>
> 
> I want to set the property 'prop' only once.
> 
> I'm using ant 1.5.3-1 and would rather not mess with any 
> additional ant
> contribution packages.
> 
> Thanks
> Christian
> 
> ---------------------------------------------------------------------
> 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