You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by jd...@apache.org on 2006/08/31 01:31:19 UTC
svn commit: r438706 - in /maven/plugins/trunk/maven-assembly-plugin/src:
it/multimodule/twoLevel-dontIncludeSubModules-artifactIdExprOutDir/src/main/assembly/
it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/
it/multimodule/twoLevel...
Author: jdcasey
Date: Wed Aug 30 16:31:18 2006
New Revision: 438706
URL: http://svn.apache.org/viewvc?rev=438706&view=rev
Log:
Adding ability to automatically exclude sub-module source dirs using excludeSubModuleDirectories flag on the sources element.
Added:
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/pom.xml (with props)
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/main/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/main/java/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/main/java/test/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/main/java/test/App.java (with props)
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/test/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/test/java/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/test/java/test/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/test/java/test/AppTest.java (with props)
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/pom.xml (with props)
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/main/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/main/java/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/main/java/test/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/main/java/test/App2.java (with props)
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/test/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/test/java/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/test/java/test/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/test/java/test/App2Test.java (with props)
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/pom.xml (with props)
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/goals.txt (with props)
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/pom.xml (with props)
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/src/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/src/main/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/src/main/assembly/
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/src/main/assembly/src.xml (with props)
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/verify.bsh
Modified:
maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-dontIncludeSubModules-artifactIdExprOutDir/src/main/assembly/src.xml
maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/ModuleSetAssemblyPhase.java
maven/plugins/trunk/maven-assembly-plugin/src/main/mdo/descriptor.mdo
maven/plugins/trunk/maven-assembly-plugin/src/test/java/org/apache/maven/plugin/assembly/archive/phase/ModuleSetAssemblyPhaseTest.java
Modified: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-dontIncludeSubModules-artifactIdExprOutDir/src/main/assembly/src.xml
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-dontIncludeSubModules-artifactIdExprOutDir/src/main/assembly/src.xml?rev=438706&r1=438705&r2=438706&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-dontIncludeSubModules-artifactIdExprOutDir/src/main/assembly/src.xml (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-dontIncludeSubModules-artifactIdExprOutDir/src/main/assembly/src.xml Wed Aug 30 16:31:18 2006
@@ -8,6 +8,7 @@
<moduleSet>
<includeSubModules>false</includeSubModules>
<sources>
+ <excludeSubModuleDirectories>false</excludeSubModuleDirectories>
<fileSets>
<fileSet>
<excludes>
Added: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/pom.xml
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/pom.xml?rev=438706&view=auto
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/pom.xml (added)
+++ maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/pom.xml Wed Aug 30 16:31:18 2006
@@ -0,0 +1,19 @@
+<?xml version="1.0"?><project>
+ <parent>
+ <groupId>test</groupId>
+ <artifactId>two-level-multimodule</artifactId>
+ <version>1.0-SNAPSHOT</version>
+ </parent>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>test</groupId>
+ <artifactId>child-level1-project1</artifactId>
+ <version>1.0-SNAPSHOT</version>
+ <dependencies>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <version>3.8.1</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+</project>
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/pom.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/pom.xml
------------------------------------------------------------------------------
svn:keywords = "Author Date Id Revision"
Added: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/main/java/test/App.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/main/java/test/App.java?rev=438706&view=auto
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/main/java/test/App.java (added)
+++ maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/main/java/test/App.java Wed Aug 30 16:31:18 2006
@@ -0,0 +1,13 @@
+package test;
+
+/**
+ * Hello world!
+ *
+ */
+public class App
+{
+ public static void main( String[] args )
+ {
+ System.out.println( "Hello World!" );
+ }
+}
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/main/java/test/App.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/main/java/test/App.java
------------------------------------------------------------------------------
svn:keywords = "Author Date Id Revision"
Added: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/test/java/test/AppTest.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/test/java/test/AppTest.java?rev=438706&view=auto
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/test/java/test/AppTest.java (added)
+++ maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/test/java/test/AppTest.java Wed Aug 30 16:31:18 2006
@@ -0,0 +1,38 @@
+package test;
+
+import junit.framework.Test;
+import junit.framework.TestCase;
+import junit.framework.TestSuite;
+
+/**
+ * Unit test for simple App.
+ */
+public class AppTest
+ extends TestCase
+{
+ /**
+ * Create the test case
+ *
+ * @param testName name of the test case
+ */
+ public AppTest( String testName )
+ {
+ super( testName );
+ }
+
+ /**
+ * @return the suite of tests being tested
+ */
+ public static Test suite()
+ {
+ return new TestSuite( AppTest.class );
+ }
+
+ /**
+ * Rigourous Test :-)
+ */
+ public void testApp()
+ {
+ assertTrue( true );
+ }
+}
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/test/java/test/AppTest.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project1/src/test/java/test/AppTest.java
------------------------------------------------------------------------------
svn:keywords = "Author Date Id Revision"
Added: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/pom.xml
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/pom.xml?rev=438706&view=auto
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/pom.xml (added)
+++ maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/pom.xml Wed Aug 30 16:31:18 2006
@@ -0,0 +1,19 @@
+<?xml version="1.0"?><project>
+ <parent>
+ <artifactId>child-level1-project2</artifactId>
+ <groupId>test</groupId>
+ <version>1.0-SNAPSHOT</version>
+ </parent>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>test</groupId>
+ <artifactId>child-level2-project1</artifactId>
+ <version>1.0-SNAPSHOT</version>
+ <dependencies>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <version>3.8.1</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+</project>
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/pom.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/pom.xml
------------------------------------------------------------------------------
svn:keywords = "Author Date Id Revision"
Added: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/main/java/test/App2.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/main/java/test/App2.java?rev=438706&view=auto
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/main/java/test/App2.java (added)
+++ maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/main/java/test/App2.java Wed Aug 30 16:31:18 2006
@@ -0,0 +1,13 @@
+package test;
+
+/**
+ * Hello world!
+ *
+ */
+public class App2
+{
+ public static void main( String[] args )
+ {
+ System.out.println( "Hello World!" );
+ }
+}
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/main/java/test/App2.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/main/java/test/App2.java
------------------------------------------------------------------------------
svn:keywords = "Author Date Id Revision"
Added: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/test/java/test/App2Test.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/test/java/test/App2Test.java?rev=438706&view=auto
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/test/java/test/App2Test.java (added)
+++ maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/test/java/test/App2Test.java Wed Aug 30 16:31:18 2006
@@ -0,0 +1,38 @@
+package test;
+
+import junit.framework.Test;
+import junit.framework.TestCase;
+import junit.framework.TestSuite;
+
+/**
+ * Unit test for simple App2.
+ */
+public class App2Test
+ extends TestCase
+{
+ /**
+ * Create the test case
+ *
+ * @param testName name of the test case
+ */
+ public App2Test( String testName )
+ {
+ super( testName );
+ }
+
+ /**
+ * @return the suite of tests being tested
+ */
+ public static Test suite()
+ {
+ return new TestSuite( App2Test.class );
+ }
+
+ /**
+ * Rigourous Test :-)
+ */
+ public void testApp2()
+ {
+ assertTrue( true );
+ }
+}
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/test/java/test/App2Test.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/child-level2-project1/src/test/java/test/App2Test.java
------------------------------------------------------------------------------
svn:keywords = "Author Date Id Revision"
Added: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/pom.xml
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/pom.xml?rev=438706&view=auto
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/pom.xml (added)
+++ maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/pom.xml Wed Aug 30 16:31:18 2006
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project>
+ <parent>
+ <groupId>test</groupId>
+ <artifactId>two-level-multimodule</artifactId>
+ <version>1.0-SNAPSHOT</version>
+ </parent>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>test</groupId>
+ <artifactId>child-level1-project2</artifactId>
+ <version>1.0-SNAPSHOT</version>
+
+ <packaging>pom</packaging>
+
+ <modules>
+ <module>child-level2-project1</module>
+ </modules>
+</project>
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/pom.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/child-level1-project2/pom.xml
------------------------------------------------------------------------------
svn:keywords = "Author Date Id Revision"
Added: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/goals.txt
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/goals.txt?rev=438706&view=auto
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/goals.txt (added)
+++ maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/goals.txt Wed Aug 30 16:31:18 2006
@@ -0,0 +1,2 @@
+clean
+assembly:directory-inline
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/goals.txt
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/goals.txt
------------------------------------------------------------------------------
svn:keywords = "Author Date Id Revision"
Added: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/pom.xml
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/pom.xml?rev=438706&view=auto
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/pom.xml (added)
+++ maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/pom.xml Wed Aug 30 16:31:18 2006
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>test</groupId>
+ <artifactId>two-level-multimodule</artifactId>
+ <version>1.0-SNAPSHOT</version>
+
+ <packaging>pom</packaging>
+
+ <modules>
+ <module>child-level1-project1</module>
+ <module>child-level1-project2</module>
+ </modules>
+
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-assembly-plugin</artifactId>
+ <configuration>
+ <descriptors>
+ <descriptor>src/main/assembly/src.xml</descriptor>
+ </descriptors>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+</project>
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/pom.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/pom.xml
------------------------------------------------------------------------------
svn:keywords = "Author Date Id Revision"
Added: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/src/main/assembly/src.xml
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/src/main/assembly/src.xml?rev=438706&view=auto
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/src/main/assembly/src.xml (added)
+++ maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/src/main/assembly/src.xml Wed Aug 30 16:31:18 2006
@@ -0,0 +1,21 @@
+<assembly>
+ <id>src</id>
+ <formats>
+ <format>dir</format>
+ </formats>
+ <includeBaseDirectory>false</includeBaseDirectory>
+ <moduleSets>
+ <moduleSet>
+ <sources>
+ <fileSets>
+ <fileSet>
+ <excludes>
+ <exclude>**/.svn</exclude>
+ <exclude>target/**</exclude>
+ </excludes>
+ </fileSet>
+ </fileSets>
+ </sources>
+ </moduleSet>
+ </moduleSets>
+</assembly>
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/src/main/assembly/src.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/src/main/assembly/src.xml
------------------------------------------------------------------------------
svn:keywords = "Author Date Id Revision"
Added: maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/verify.bsh
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/verify.bsh?rev=438706&view=auto
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/verify.bsh (added)
+++ maven/plugins/trunk/maven-assembly-plugin/src/it/multimodule/twoLevel-includeSubModules-excludeSubModuleSourceDirs/verify.bsh Wed Aug 30 16:31:18 2006
@@ -0,0 +1,21 @@
+import java.io.*;
+import java.net.*;
+import java.util.jar.*;
+
+boolean result = true;
+
+result = result && new File( basedir, "target/two-level-multimodule-1.0-SNAPSHOT-src.dir/child-level1-project1/pom.xml" ).exists();
+
+result = result && new File( basedir, "target/two-level-multimodule-1.0-SNAPSHOT-src.dir/child-level1-project2/pom.xml" ).exists();
+
+result = result && new File( basedir, "target/two-level-multimodule-1.0-SNAPSHOT-src.dir/child-level2-project1/pom.xml" ).exists();
+
+result = result && !new File( basedir, "target/two-level-multimodule-1.0-SNAPSHOT-src.dir/child-level1-project2/child-level2-project1/pom.xml" ).exists();
+
+result = result && !new File( basedir, "target/two-level-multimodule-1.0-SNAPSHOT-src.dir/child-level1-project1/target" ).exists();
+
+result = result && !new File( basedir, "target/two-level-multimodule-1.0-SNAPSHOT-src.dir/child-level1-project2/target" ).exists();
+
+result = result && !new File( basedir, "target/two-level-multimodule-1.0-SNAPSHOT-src.dir/child-level2-project1/target" ).exists();
+
+return result;
Modified: maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/ModuleSetAssemblyPhase.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/ModuleSetAssemblyPhase.java?rev=438706&r1=438705&r2=438706&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/ModuleSetAssemblyPhase.java (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/ModuleSetAssemblyPhase.java Wed Aug 30 16:31:18 2006
@@ -286,7 +286,28 @@
fs.setDirectory( sourcePath );
fs.setDirectoryMode( fileSet.getDirectoryMode() );
- fs.setExcludes( fileSet.getExcludes() );
+
+ List excludes = new ArrayList();
+
+ List originalExcludes = fileSet.getExcludes();
+ if ( originalExcludes != null && !originalExcludes.isEmpty() )
+ {
+ excludes.addAll( originalExcludes );
+ }
+
+ if ( sources.isExcludeSubModuleDirectories() )
+ {
+ List modules = moduleProject.getModules();
+ for ( Iterator moduleIterator = modules.iterator(); moduleIterator.hasNext(); )
+ {
+ String moduleSubPath = ( String ) moduleIterator.next();
+
+ excludes.add( moduleSubPath + "/**" );
+ }
+ }
+
+ fs.setExcludes( excludes );
+
fs.setFileMode( fileSet.getFileMode() );
fs.setIncludes( fileSet.getIncludes() );
fs.setLineEnding( fileSet.getLineEnding() );
Modified: maven/plugins/trunk/maven-assembly-plugin/src/main/mdo/descriptor.mdo
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/main/mdo/descriptor.mdo?rev=438706&r1=438705&r2=438706&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/main/mdo/descriptor.mdo (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/main/mdo/descriptor.mdo Wed Aug 30 16:31:18 2006
@@ -582,6 +582,21 @@
</description>
</field>
<field>
+ <name>excludeSubModuleDirectories</name>
+ <version>1.0.0</version>
+ <type>boolean</type>
+ <defaultValue>true</defaultValue>
+ <description>
+ <![CDATA[
+ Specifies whether sub-module directories below the current module should be excluded
+ from fileSets applied to that module. This might be useful if you only mean to copy
+ the sources for the exact module list matched by this ModuleSet, ignoring (or processing
+ separately) the modules which exist in directories below the current one.
+ Default value is true.
+ ]]>
+ </description>
+ </field>
+ <field>
<name>outputFileNameMapping</name>
<version>1.0.0</version>
<type>String</type>
Modified: maven/plugins/trunk/maven-assembly-plugin/src/test/java/org/apache/maven/plugin/assembly/archive/phase/ModuleSetAssemblyPhaseTest.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/test/java/org/apache/maven/plugin/assembly/archive/phase/ModuleSetAssemblyPhaseTest.java?rev=438706&r1=438705&r2=438706&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/test/java/org/apache/maven/plugin/assembly/archive/phase/ModuleSetAssemblyPhaseTest.java (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/test/java/org/apache/maven/plugin/assembly/archive/phase/ModuleSetAssemblyPhaseTest.java Wed Aug 30 16:31:18 2006
@@ -123,6 +123,46 @@
mm.verifyAll();
}
+ public void testCreateFileSet_ShouldAddExcludesForSubModulesWhenExcludeSubModDirsIsTrue()
+ throws AssemblyFormattingException
+ {
+ MockManager mm = new MockManager();
+
+ FileSet fs = new FileSet();
+
+ ModuleSources sources = new ModuleSources();
+ sources.setExcludeSubModuleDirectories( true );
+
+ Model model = new Model();
+ model.setArtifactId( "artifact" );
+
+ model.addModule( "submodule" );
+
+ MavenProject project = new MavenProject( model );
+
+ File basedir = fileManager.createTempDir();
+
+ project.setFile( new File( basedir, "pom.xml" ) );
+
+ MockAndControlForArtifact macArtifact = new MockAndControlForArtifact( mm );
+
+ macArtifact.expectIsSnapshot( false );
+ macArtifact.expectGetClassifier( null );
+ macArtifact.expectGetArtifactHandler();
+
+ project.setArtifact( macArtifact.artifact );
+
+ mm.replayAll();
+
+ FileSet result =
+ createPhase( new ConsoleLogger( Logger.LEVEL_DEBUG, "test" ), null ).createFileSet( fs, sources, project );
+
+ assertEquals( 1, result.getExcludes().size() );
+ assertEquals( "submodule/**", result.getExcludes().get( 0 ) );
+
+ mm.verifyAll();
+ }
+
public void testExecute_ShouldSkipIfNoModuleSetsFound()
throws ArchiveCreationException, AssemblyFormattingException, InvalidAssemblerConfigurationException
{