You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by jmaxwell <je...@gmail.com> on 2009/02/16 20:40:04 UTC
Shared Assembly Descriptor Property Evaluation Issue
When using a shared assembly descriptor the ${artifact.id} and ${project.id}
properties are set to the shared assembly descriptor values and NOT to the
values of the executing project.
Tested on:
Assembly plugin: 2.2-beta-3 and 2.2-beta-2.
Maven: 2.0.9, 2.0.10, M2Eclipse Embedded
JDK: Sun 1.6.0_07
OS: Vista
Assembly Descriptor:
<assembly>
<id>springbatch</id>
<formats>
<format>zip</format>
</formats>
<includeBaseDirectory>false</includeBaseDirectory>
<fileSets>
<fileSet>
<directory>src/main/config</directory>
<includes>
<include>*.properties</include>
</includes>
<outputDirectory>/conf</outputDirectory>
<filtered>true</filtered>
</fileSet>
<fileSet>
<directory>src/main/resources/jobs</directory>
<outputDirectory>jobs</outputDirectory>
</fileSet>
</fileSets>
<dependencySets>
<dependencySet>
<outputFileNameMapping>${artifact.artifactId}-${artifact.baseVersion}.${artifact.extension}
</outputFileNameMapping>
<outputDirectory>/lib</outputDirectory>
<unpack>false</unpack>
<scope>runtime</scope>
<excludes>
<exclude>${project.id}</exclude>
</excludes>
</dependencySet>
<dependencySet>
<unpack>false</unpack>
<includes>
<include>${project.id}</include>
</includes>
</dependencySet>
</dependencySets>
</assembly>
Debug output:
[DEBUG] Configuring mojo
'org.apache.maven.plugins:maven-assembly-plugin:2.2-beta-3:single' -->
[DEBUG] (s) appendAssemblyId = true
[DEBUG] (f) attach = true
[DEBUG] (s) basedir = C:\projects\080066\common\common-util
[DEBUG] (s) descriptor = springbatch.xml
[DEBUG] (s) descriptorSourceDirectory =
C:\projects\080066\common\common-util\src\main\assembly
[DEBUG] (f) dryRun = false
[DEBUG] (s) finalName = common-util-1.1-SNAPSHOT
[DEBUG] (f) ignoreDirFormatExtensions = true
[DEBUG] (s) ignoreMissingDescriptor = false
[DEBUG] (s) includeSite = false
[DEBUG] (s) localRepository = [local] ->
file://C:\Users\jmaxwell\.m2\repository
[DEBUG] (f) mavenSession = org.apache.maven.execution.MavenSession@cffc79
[DEBUG] (s) outputDirectory = C:\projects\080066\common\common-util\target
[DEBUG] (f) project = MavenProject:
com.clearingcorp:common-util:1.1-SNAPSHOT @
C:\projects\080066\common\common-util\pom.xml
[DEBUG] (s) reactorProjects = [MavenProject:
com.clearingcorp:common-util:1.1-SNAPSHOT @
C:\projects\080066\common\common-util\pom.xml]
[DEBUG] (f) remoteRepositories = [[central] -> http://central, [releases]
-> http://localhost:8082/nexus/content/repositories/releases, [snapshots] ->
http://localhost:8082/nexus/content/repositories/snapshots]
[DEBUG] (s) siteDirectory =
C:\projects\080066\common\common-util\target\site
[DEBUG] (f) skipAssembly = false
[DEBUG] (s) tarLongFileMode = warn
[DEBUG] (s) tempRoot =
C:\projects\080066\common\common-util\target\archive-tmp
[DEBUG] (s) workDirectory =
C:\projects\080066\common\common-util\target\assembly\work
[DEBUG] -- end configuration --
[INFO] [assembly:single]
[DEBUG] Before assembly is interpolated:
<?xml version="1.0" encoding="UTF-8"?><assembly>
<id>springbatch</id>
<formats>
<format>zip</format>
</formats>
<includeBaseDirectory>false</includeBaseDirectory>
<fileSets>
<fileSet>
<directory>src/main/config</directory>
<filtered>true</filtered>
<outputDirectory>/conf</outputDirectory>
<includes>
<include>*.properties</include>
</includes>
</fileSet>
<fileSet>
<directory>src/main/resources/jobs</directory>
<outputDirectory>jobs</outputDirectory>
</fileSet>
</fileSets>
<dependencySets>
<dependencySet>
<outputFileNameMapping>maven-assemblies-${artifact.baseVersion}.${artifact.extension}</outputFileNameMapping>
<outputDirectory>/lib</outputDirectory>
<excludes>
<exclude>com.clearingcorp:maven-assemblies:jar:1.1-SNAPSHOT</exclude>
</excludes>
</dependencySet>
<dependencySet>
<includes>
<include>com.clearingcorp:maven-assemblies:jar:1.1-SNAPSHOT</include>
</includes>
</dependencySet>
</dependencySets>
</assembly>
--
View this message in context: http://www.nabble.com/Shared-Assembly-Descriptor-Property-Evaluation-Issue-tp22044271p22044271.html
Sent from the Maven Developers mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: Shared Assembly Descriptor Property Evaluation Issue
Posted by jmaxwell <je...@gmail.com>.
Whoops....I had the filtering on for my src/main/resources/assemblies
directory.
jmaxwell wrote:
>
> When using a shared assembly descriptor the ${artifact.id} and
> ${project.id} properties are set to the shared assembly descriptor values
> and NOT to the values of the executing project.
>
> Tested on:
> Assembly plugin: 2.2-beta-3 and 2.2-beta-2.
> Maven: 2.0.9, 2.0.10, M2Eclipse Embedded
> JDK: Sun 1.6.0_07
> OS: Vista
>
> Assembly Descriptor:
> <assembly>
> <id>springbatch</id>
> <formats>
> <format>zip</format>
> </formats>
> <includeBaseDirectory>false</includeBaseDirectory>
> <fileSets>
> <fileSet>
> <directory>src/main/config</directory>
> <includes>
> <include>*.properties</include>
> </includes>
> <outputDirectory>/conf</outputDirectory>
> <filtered>true</filtered>
> </fileSet>
> <fileSet>
> <directory>src/main/resources/jobs</directory>
> <outputDirectory>jobs</outputDirectory>
> </fileSet>
> </fileSets>
>
> <dependencySets>
> <dependencySet>
>
> <outputFileNameMapping>${artifact.artifactId}-${artifact.baseVersion}.${artifact.extension}
> </outputFileNameMapping>
> <outputDirectory>/lib</outputDirectory>
> <unpack>false</unpack>
> <scope>runtime</scope>
> <excludes>
> <exclude>${project.id}</exclude>
> </excludes>
> </dependencySet>
>
> <dependencySet>
> <unpack>false</unpack>
> <includes>
> <include>${project.id}</include>
> </includes>
> </dependencySet>
> </dependencySets>
> </assembly>
>
>
> Debug output:
>
> [DEBUG] Configuring mojo
> 'org.apache.maven.plugins:maven-assembly-plugin:2.2-beta-3:single' -->
> [DEBUG] (s) appendAssemblyId = true
> [DEBUG] (f) attach = true
> [DEBUG] (s) basedir = C:\projects\080066\common\common-util
> [DEBUG] (s) descriptor = springbatch.xml
> [DEBUG] (s) descriptorSourceDirectory =
> C:\projects\080066\common\common-util\src\main\assembly
> [DEBUG] (f) dryRun = false
> [DEBUG] (s) finalName = common-util-1.1-SNAPSHOT
> [DEBUG] (f) ignoreDirFormatExtensions = true
> [DEBUG] (s) ignoreMissingDescriptor = false
> [DEBUG] (s) includeSite = false
> [DEBUG] (s) localRepository = [local] ->
> file://C:\Users\jmaxwell\.m2\repository
> [DEBUG] (f) mavenSession =
> org.apache.maven.execution.MavenSession@cffc79
> [DEBUG] (s) outputDirectory =
> C:\projects\080066\common\common-util\target
> [DEBUG] (f) project = MavenProject:
> com.clearingcorp:common-util:1.1-SNAPSHOT @
> C:\projects\080066\common\common-util\pom.xml
> [DEBUG] (s) reactorProjects = [MavenProject:
> com.clearingcorp:common-util:1.1-SNAPSHOT @
> C:\projects\080066\common\common-util\pom.xml]
> [DEBUG] (f) remoteRepositories = [[central] -> http://central,
> [releases] -> http://localhost:8082/nexus/content/repositories/releases,
> [snapshots] -> http://localhost:8082/nexus/content/repositories/snapshots]
> [DEBUG] (s) siteDirectory =
> C:\projects\080066\common\common-util\target\site
> [DEBUG] (f) skipAssembly = false
> [DEBUG] (s) tarLongFileMode = warn
> [DEBUG] (s) tempRoot =
> C:\projects\080066\common\common-util\target\archive-tmp
> [DEBUG] (s) workDirectory =
> C:\projects\080066\common\common-util\target\assembly\work
> [DEBUG] -- end configuration --
> [INFO] [assembly:single]
> [DEBUG] Before assembly is interpolated:
>
> <?xml version="1.0" encoding="UTF-8"?><assembly>
> <id>springbatch</id>
> <formats>
> <format>zip</format>
> </formats>
> <includeBaseDirectory>false</includeBaseDirectory>
> <fileSets>
> <fileSet>
> <directory>src/main/config</directory>
> <filtered>true</filtered>
> <outputDirectory>/conf</outputDirectory>
> <includes>
> <include>*.properties</include>
> </includes>
> </fileSet>
> <fileSet>
> <directory>src/main/resources/jobs</directory>
> <outputDirectory>jobs</outputDirectory>
> </fileSet>
> </fileSets>
> <dependencySets>
> <dependencySet>
>
> <outputFileNameMapping>maven-assemblies-${artifact.baseVersion}.${artifact.extension}</outputFileNameMapping>
> <outputDirectory>/lib</outputDirectory>
> <excludes>
>
> <exclude>com.clearingcorp:maven-assemblies:jar:1.1-SNAPSHOT</exclude>
> </excludes>
> </dependencySet>
> <dependencySet>
> <includes>
>
> <include>com.clearingcorp:maven-assemblies:jar:1.1-SNAPSHOT</include>
> </includes>
> </dependencySet>
> </dependencySets>
> </assembly>
>
>
--
View this message in context: http://www.nabble.com/Shared-Assembly-Descriptor-Property-Evaluation-Issue-tp22044271p22066125.html
Sent from the Maven Developers mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org