ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stephane Chauvin <SChau...@cardiff.com>
Subject RE: [SUBMIT] FilterReader for compilation directives
Date Wed, 14 Aug 2002 19:30:39 GMT
I have exactly the same approach.
The proposed task works also for several type of file (JAVA, JSP).
In this case we don't need to provide the value for the replacement. So we
do not care about the token value for the beginning, the end or even for the
line. 
It is designed to add or remove a line/block comment. 
It is a wrapping of this idea for a more general usage.

For this FAQ:
<!-- Activate the Cactus web.xml configuration -->
<copy todir="${admin.build.dir}/WEB-INF"
      file="web/admin/WEB-INF/web.xml"
      overwrite="yes">
  <filterchain>
    <filterreader classname="org.apache.tools.ant.filters.CommentOut"/>
  </filterchain>
</copy>

<!-- Begin Cactus Configuration -->
<!-- @IF_BLOCK@ cactus.config
...
@IF_END@ cactus.config-->
<!-- End Cactus Configuration -->

It has for effect to disable the "cactus.config" condition.

Stephane.

-----Original Message-----
From: Erik Hatcher [mailto:jakarta-ant@ehatchersolutions.com]
Sent: Wednesday, August 14, 2002 11:55 AM
To: Ant Developers List
Subject: Re: [SUBMIT] FilterReader for compilation directives


How about this technique instead?

	http://jakarta.apache.org/cactus/faq.html#faq2



--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message