You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Steve Cohen <sc...@javactivity.org> on 2010/07/22 16:53:48 UTC

not respected in assembly descriptor within

Given the following POM and assembly descriptor, and assuming that one
or more of the submodules defined has a transitive test-scope dependency
on JUnit, I find that when I run my assembly, all works as expected
except that JUnit is included in the assembly archive.  I would prefer
that it not be, and it seems from the documentation that it should not be.

Is this a bug, or am I making a mistake in the assembly descriptor
definition?

<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>com.whatever</groupId>
  <artifactId>xyz</artifactId>
  <version>0.0.1-SNAPSHOT</version>
  <packaging>pom</packaging>
  <name>xyz</name>
  <description>This is a project which exists simply to build the xyz
deployment archive</description>
  <build>
    <plugins>
       	<plugin>
 	<groupId>org.apache.maven.plugins</groupId>
	<artifactId>maven-assembly-plugin</artifactId>
	<version>2.2-beta-5</version>
	<configuration>
	<descriptor>src/main/assembly/zip.xml</descriptor>
					<finalName>${TAG}</finalName>
			<appendAssemblyId>false</appendAssemblyId>
	</configuration>
	</plugin>
  </plugins>
  </build>

  <dependencyManagement>
  	<dependencies>
  	</dependencies>
  </dependencyManagement>
  <modules>
  	<module>../submodule1</module>
  	<module>../submodule2</module>
  	<module>../submodule3</module>
  </modules>
</project>

=============================================================================

<?xml version="1.0" encoding="UTF-8"?>
<assembly>
<id>xyz</id>
   <formats>
     <format>zip</format>
    </formats>
    <baseDirectory>xyz</baseDirectory>
    <moduleSets>
    <moduleSet>
      <binaries>
        <outputDirectory>lib</outputDirectory>
	<includeDependencies/>
	<dependencySets>
	<dependencySet>
          <scope>runtime</scope>
	  <outputDirectory>lib</outputDirectory>
          <useTransitiveDependencies/>
          <useTransitiveFiltering/>
	</dependencySet>
	</dependencySets>
        <unpack>false</unpack>
      </binaries>
    </moduleSet>
  </moduleSets>
	
  <fileSets>
  <fileSet>
    <directory>unpackaged/config</directory>
    <outputDirectory>config</outputDirectory>
      <includes>
	<include>**</include>
      </includes>
   </fileSet>
   </fileSets>
</assembly>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org