You are viewing a plain text version of this content. The canonical link for it is here.
Posted to scm@geronimo.apache.org by jd...@apache.org on 2006/08/22 06:47:59 UTC
svn commit: r433511 - /geronimo/genesis/trunk/config/project-config/pom.xml
Author: jdillon
Date: Mon Aug 21 21:47:59 2006
New Revision: 433511
URL: http://svn.apache.org/viewvc?rev=433511&view=rev
Log:
Add LICENSE.txt and NOTICE.txt to target/classes/META-INF if the packaging is not pom using groovy to not conflict with children's use of antrun
Modified:
geronimo/genesis/trunk/config/project-config/pom.xml
Modified: geronimo/genesis/trunk/config/project-config/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/genesis/trunk/config/project-config/pom.xml?rev=433511&r1=433510&r2=433511&view=diff
==============================================================================
--- geronimo/genesis/trunk/config/project-config/pom.xml (original)
+++ geronimo/genesis/trunk/config/project-config/pom.xml Mon Aug 21 21:47:59 2006
@@ -166,15 +166,6 @@
<resources>
<resource>
- <directory>${pom.basedir}</directory>
- <targetPath>META-INF</targetPath>
- <includes>
- <include>LICENSE.txt</include>
- <include>NOTICE.txt</include>
- </includes>
- </resource>
-
- <resource>
<directory>${pom.basedir}/src/main/resources</directory>
</resource>
</resources>
@@ -334,6 +325,45 @@
</plugin>
<!--
+ NOTE: Install LICENSE.txt and NOTICE.txt into the classes directory.
+
+ Using a resource will cause some uneeded havok on some plugins
+ like maven-eclipse-plugin.
+
+ Not using antrun, as when we use it here it causes failures down the line
+ because Maven will not honor the local dependencies.
+ -->
+ <plugin>
+ <groupId>org.apache.geronimo.genesis.plugins</groupId>
+ <artifactId>script-maven-plugin</artifactId>
+ <version>1.0.0-SNAPSHOT</version>
+ <executions>
+ <execution>
+ <phase>generate-resources</phase>
+ <goals>
+ <goal>groovy</goal>
+ </goals>
+ <configuration>
+ <code>
+ if (project.packaging != "pom") {
+ def ant = new AntBuilder()
+
+ def dir = "${project.basedir}/target/classes/META-INF"
+ ant.mkdir(dir: dir)
+ ant.copy(todir: dir) {
+ fileset(dir: "${project.basedir}") {
+ include(name: "LICENSE.txt")
+ include(name: "NOTICE.txt")
+ }
+ }
+ }
+ </code>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+
+ <!--
NOTE: Project pom should define:
<plugin>
@@ -343,7 +373,7 @@
<source>1.4</source>
<target>1.4</target>
</configuration>
- </plugin>
+ </plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>