Hi All,

I've spent quite a while (long enough to resort to the email list :) )
trying to get maven 1.02, while building a war, to replace a variable
in my web.xml file that looks like this :
        <param-value>@pom.config-dir@/log4j.xml</param-value>

Just about everything I found on the web says to define an ant filter
before the war-resources step like so :
        <preGoal name="war:war-resources">
                <ant:filter token="pom.config-dir"
value="${pom.artifactId}/${pom.currentVersion}" />
        </preGoal>

There's a quick blurb about this at the bottom of this page :
http://maven.apache.org/maven-1.x/plugins/war/.

I actually do this successfully in my project for the
java:jar-resources command.  Project.xml file has the <resources>
explicitly defined, and the ant copy command kicks in on files defined
there just fine and the filter works accordingly.

However, with building a war, this doesn't work.  I've tried a million
different tweaks but for whatever reason the copy command built into
the war target in maven is not picking up the ant filter.  I tried
setting maven.war.src.filtering to true, but it defaults true and it
hasn't worked.

Before I try a hack around it by definding a <ant replace> in a
<postGoal name="war:war-resources">, I wondered if anyone had got
something like this to work before.  I can't upgrade maven to 2.0, we
are stuck on the earlier version.  Thanks a bunch,

-Glenn

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to