You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tapestry.apache.org by hl...@apache.org on 2009/01/24 02:17:12 UTC
svn commit: r737282 - in /tapestry/tapestry5/trunk: pom.xml
src/site/fml/faq/general.fml
Author: hlship
Date: Sat Jan 24 01:17:12 2009
New Revision: 737282
URL: http://svn.apache.org/viewvc?rev=737282&view=rev
Log:
TAP5-346: Maven resource filtering pre-expands some Tapestry expansions: docs should warn of this
Modified:
tapestry/tapestry5/trunk/pom.xml
tapestry/tapestry5/trunk/src/site/fml/faq/general.fml
Modified: tapestry/tapestry5/trunk/pom.xml
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/pom.xml?rev=737282&r1=737281&r2=737282&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/pom.xml (original)
+++ tapestry/tapestry5/trunk/pom.xml Sat Jan 24 01:17:12 2009
@@ -206,8 +206,6 @@
<plugin>
<artifactId>maven-site-plugin</artifactId>
- <!-- Snapshots after this are broken. %#%#%$#@% Maven. TAPESTRY-1943 -->
- <version>2.0-beta-5</version>
</plugin>
<!-- We configure this either way, but it's only active when the "deploy" profile is active. -->
Modified: tapestry/tapestry5/trunk/src/site/fml/faq/general.fml
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/src/site/fml/faq/general.fml?rev=737282&r1=737281&r2=737282&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/src/site/fml/faq/general.fml (original)
+++ tapestry/tapestry5/trunk/src/site/fml/faq/general.fml Sat Jan 24 01:17:12 2009
@@ -331,5 +331,47 @@
</p>
</answer>
</faq>
+ <faq id="maven-filter">
+ <question>
+ Why do Maven project names and other details show up in my pages?
+ </question>
+ <answer>
+ <p>
+ Tapestry and Maven both use the same syntax for dynamic portions of files:
+ the
+ <code>${...}</code>
+ syntax. When Maven is copying resources from
+ src/main/resources, and when filtering is enabled (which is not the default),
+ then any expansions in
+ <em>Tapestry templates</em>
+ that match against
+ Maven project properties are substituted. If you look at the deployed
+ application, you'll see that
+ <code>${name}</code>
+ is gone, replaced with the
+ project name!
+ </p>
+ <p>
+ The solution is to update your pom.xml to ignore any .tml files when copying and filtering:
+ </p>
+ <pre>
+ <resource>
+ <directory>src/main/resources</directory>
+ <excludes>
+ <exclude>**/*.tml</exclude>
+ </excludes>
+ <filtering>true</filtering>
+ </resource>
+
+ <resource>
+ <directory>src/main/resources</directory>
+ <includes>
+ <include>**/*.tml</include>
+ </includes>
+ <filtering>false</filtering>
+ </resource>
+ </pre>
+ </answer>
+ </faq>
</part>
</faqs>
\ No newline at end of file