ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erik Hatcher <jakarta-...@ehatchersolutions.com>
Subject Re: howto stripp html comments
Date Mon, 26 May 2003 23:59:45 GMT
If you're trying to comment JSP files, but not incur the bandwidth to 
send the comments to the browser, how about using the server-side JSP 
comment tag?

<%-- this is a JSP comment --%>

	http://java.sun.com/products/jsp/tags/11/syntaxref11.fm2.html  (first 
hit on Google: JSP comment syntax)

Erik


On Monday, May 26, 2003, at 07:56  PM, James Nord wrote:
> Hi,
>
> I want to strip all html comments from jsp files during a build, but I 
> can't work out how to do it as a always end up with the following > error
>
> file:D:/src/build.xml:100: The value of attribute "pattern" must not 
> contain the '<' character.
>
> (result from)
>  <target name="jsp" depends="init"
>          description="copy jsp files and strip comments">
>        <mkdir dir="${build.dir}/jsp"/>
>    <copy todir="${build.dir}/jsp">
>      <fileset dir="${src.dir}/jsp"/>
>    </copy>
>    <replaceregexp byline="true">
>      <regexp pattern="<!--[:alnum:\w]*-->"/>
>      <substitution expression=""/>
>      <fileset dir="{src.dir}/jsp"/>
>   </replaceregexp>
>  </target>
>
> Could someone tell me how to include the > character?  I have tried \> 
> and \\> but with the same results.
>
> Thanks in advance
>
>    /James
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
>


Mime
View raw message