ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hagen, Christian" <cha...@init-ka.de>
Subject Using property in regexp mapper
Date Fri, 13 Feb 2004 16:06:25 GMT
Hi,

I have the following problem (ANT 1.6.0, Windows 2000) with copy using a
mapper:

I have a property file, which is loaded first:

prod.A.target = targetA
prod.B.target = targetB
prod.C.target = targetC


The copying should do the following:

src/prod/A/config/configA.xml  -->
target/${prod.A.target}/config/configA.xml
src/prod/B/config/configB.xml  -->
target/${prod.B.target}/config/configB.xml


I tried to copy it with a mapper:

<copy preservelastmodified="true" verbose="true" todir="target">
  <fileset dir="src"/>
  <mapper type="regexp" from="prod/(.*)/config/(.*)"
to="${prod.\1.target}/config/\2"/>
</copy>


It does not work telling me: "Property ${prod.\1.target} has not been
set".

Does this mean the property is resolved before inserting the regexp
group?
Does anybody know another way to do the copying?



Thanks in advance.

Chris

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


Mime
View raw message