ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chuck Brunson <>
Subject Re: Use properties in regular expressions
Date Mon, 14 Oct 2002 15:04:54 GMT
Shawn Wilson wrote:

> Hi,
> I'm using the <replaceregexp> tag and I'm wondering if I can refer to a 
> property value within the 'replace' attribute of the tag. I don't see 
> any mention in the documentation about how this might be accomplished, 
> if it can at all.
> Thanks,
> -shawn

Sure, here's an example:

<replaceregexp file="${testx.tomcat_base}/conf/server.xml"

We read in the testx vals from a file in the user's homedir like
testx.propsfile:     ${user.home}/
<property file="${testx.propsfile}"/>

And then we use those to replacements like the one above. testx
is just an identifier we use for tests that require something
else running like tomcat.

					Chuck Brunson
					AIM: chuck9206

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message