Java Mailing List Archive

http://www.ant-tasks.com/

Home » Ant Users List »

how to use @@ ?

Alberto Ivo

2008-04-29

Replies:

Author LoginPost Reply
hello guys...

I just subscribe the list.. this is my very first post here..

I have a situation here... I would like to know how to substitute some line
code via ant. let me explain better:

In my hibernate.cfg.xml I have the lines:

    <!-- Tomcat -->
    <property
name="connection.datasource">java:/comp/env/jdbc/pmpcDS</property>

    <!-- Weblogic -->
    <property name="connection.datasource">jdbc/pmpcDS</property>

When I'm developing, I use the tomcat datasource and comment the weblogic
datasource, when I generate the WAR to send to the server, I comment the
tomcat line and take the comment ooff the weblogic line..

I would like to know how to automatize this with ant.. I saw that I could
substitute the lines with @@linecode@@(protected)..


could anyone indicates a good tutorial for that.. or send me a example of
code??


thanks in advance...
©2008 ant-tasks.com - Jax Systems, LLC, U.S.A.