You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Jochen Wiedmann <jo...@gmail.com> on 2005/12/09 15:42:26 UTC
Questions on assembly plugin
Hi,
I'd like to use the assembly plugin for creating distributions. After
reading the documentation and doing some first attempts, I do have the
following questions:
- There are predefined ID's like "bin" and "src". These are (to me) very welcome
for reading as examples. However, they do not really meet my requirements.
I'd like to override them. Is that possible?
- In my project I will typically always use "bin" and "src". It would
be nice, if I
could configure both into the POM, so that an invocation of "mvn
assembly:assembly"
will create these two files. However, it only seems possible to
create a single
file.
In both cases: Do I miss something? If not, would a patch for changing
the plugins behaviour and/or features be welcome?
Regards,
Jochen
--
Often it does seem a pity that Noah and his party did not miss the
boat. (Mark Twain)
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Questions on assembly plugin
Posted by Jochen Wiedmann <jo...@gmail.com>.
Jochen Wiedmann wrote:
>
> Sorry, but this seems to become a never ending story.
Just a remeark: The endless loop is still present with Maven 2.0.1.
Jochen
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Questions on assembly plugin
Posted by Jochen Wiedmann <jo...@gmail.com>.
Sorry, but this seems to become a never ending story.
As suggested on this list, I have added two "execution" steps to my POM.
Both have different ID's. (See below.) However, if I do an "mvn
package", or "mvn assembly:assembly" now, then an endless loop begins.
Any idea, what's wrong? I have tried the latest version of the assembly
plugin from SVN. The POM is below. You can also reproduce the problem
quite easily:
# Checkout revision 356376 of Apache XML-RPC
svn co -r 356376
http://svn.apache.org/repos/asf/webservices/xmlrpc/branches/XMLRPC_2_0_BRANCH
xml-rpc-2
# Run the assembly plugin
cd xml-rpc-2
mvn package
# Or "mavn assembly:assembly", doesn't matter
Regards,
Jochen
<?xml version="1.0" encoding="UTF-8"?>
<project>
<modelVersion>4.0.0</modelVersion>
<groupId>org.apache.ws.xmlrpc</groupId>
<artifactId>xmlrpc</artifactId>
<name>Apache XML-RPC</name>
<version>2.0.1-SNAPSHOT</version>
<description>
Apache XML-RPC is a Java implementation of XML-RPC, a popular
protocol
that uses XML over HTTP to implement remote procedure calls.
Compared to SOAP, or JAX-RPC, it is stable, much simpler and
easier to
handle.
</description>
<url>http://ws.apache.org/xmlrpc/</url>
<issueManagement>
<system>jira</system>
<url>http://issues.apache.org/jira/browse/XMLRPC</url>
</issueManagement>
<ciManagement>
<system>Gump</system>
<url>http://vmgump.apache.org/gump/public/ws-xmlrpc/xmlrpc/index.html</url>
</ciManagement>
<inceptionYear>2001</inceptionYear>
<mailingLists>
<mailingList>
<name>XML-RPC Users</name>
<subscribe>xmlrpc-user-subscribe@ws.apache.org</subscribe>
<unsubscribe>xmlrpc-user-unsubscribe@ws.apache.org</unsubscribe>
<post>xmlrpc-user@ws.apache.org</post>
<archive>http://mail-archives.apache.org/mod_mbox/ws-xmlrpc-user/</archive>
<otherArchives>
<otherArchive>http://marc.theaimsgroup.com/?l=xmlrpc-user</otherArchive>
</otherArchives>
</mailingList>
<mailingList>
<name>XML-RPC Developers</name>
<subscribe>xmlrpc-dev-subscribe@ws.apache.org</subscribe>
<unsubscribe>xmlrpc-dev-unsubscribe@ws.apache.org</unsubscribe>
<post>xmlrpc-dev@ws.apache.org</post>
<archive>http://mail-archives.apache.org/mod_mbox/ws-xmlrpc-dev/</archive>
<otherArchives>
<otherArchive>http://marc.theaimsgroup.com/?l=xmlrpc-dev</otherArchive>
</otherArchives>
</mailingList>
</mailingLists>
<developers>
<developer>
<name>Andrew Evers</name>
<id>aevers</id>
<email>aevers@redwood.nl</email>
</developer>
<developer>
<name>Siegfried Goeschl</name>
<id>sgoeschl</id>
<email>sgoeschl@apache.org</email>
</developer>
<developer>
<name>Henri Gomez</name>
<id>hgomez</id>
<email>hgomez@apache.org</email>
</developer>
<developer>
<name>Ryan Hoegg</name>
<id>rhoegg</id>
<email>rhoegg@isisnetworks.net</email>
<organization>ISIS Networks</organization>
</developer>
<developer>
<name>Daniel Rall</name>
<id>dlr</id>
<email>dlr@finemaltcoding.com</email>
<organization>CollabNet, Inc.</organization>
</developer>
<developer>
<name>Leonard Richarson</name>
<id>leonardr</id>
<email>leonardr@collab.net</email>
<organization>CollabNet, Inc.</organization>
</developer>
<developer>
<name>Jon Scott Stevens</name>
<id>jon</id>
<email>jon@latchkey.com</email>
<organization>CollabNet, Inc.</organization>
</developer>
<developer>
<name>Hannes Wallnoefer</name>
<id>hannes</id>
<email>hannes@apache.org</email>
</developer>
<developer>
<name>Jochen Wiedmann</name>
<id>jochen</id>
<email>jochen.wiedmann@gmail.com</email>
</developer>
<developer>
<name>John Wilson</name>
<id>jwilson</id>
<email>tug@wilson.co.uk</email>
<organization>The Wilson Partnership</organization>
</developer>
<developer>
<name>Jason van Zyl</name>
<id>jvanzyl</id>
<email>jason@zenplex.com</email>
<organization>Zenplex</organization>
</developer>
</developers>
<licenses>
<license>
<name>The Apache Software License, Version 2.0</name>
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
<distribution>repo</distribution>
</license>
</licenses>
<scm>
<connection>scm:svn:http://svn.apache.org/repos/asf/webservices/xmlrpc/</connection>
<developerConnection>scm:svn:https://svn.apache.org/repos/asf/webservices/xmlrpc/</developerConnection>
<tag>XMLRPC_2_0_BRANCH/</tag>
<url>http://svn.apache.org/viewcvs.cgi/webservices/xmlrpc/</url>
</scm>
<organization>
<name>Apache Software Foundation</name>
<url>http://www.apache.org/</url>
</organization>
<build>
<sourceDirectory>src/java</sourceDirectory>
<testSourceDirectory>src/test</testSourceDirectory>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.2</source>
<target>1.1</target>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
<version>2.1-SNAPSHOT</version>
<executions>
<execution>
<id>src-assembly</id>
<phase>package</phase>
<configuration>
<descriptor>src/main/assembly/src.xml</descriptor>
</configuration>
<goals>
<goal>assembly</goal>
</goals>
</execution>
<execution>
<id>bin-assembly</id>
<phase>package</phase>
<configuration>
<descriptor>src/main/assembly/bin.xml</descriptor>
<includeSite>true</includeSite>
</configuration>
<goals>
<goal>assembly</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>commons-httpclient</groupId>
<artifactId>commons-httpclient</artifactId>
<version>2.0.2</version>
</dependency>
<dependency>
<groupId>commons-codec</groupId>
<artifactId>commons-codec</artifactId>
<version>1.3</version>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>
<version>2.2</version>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
</dependencies>
<reporting>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
</plugin>
</plugins>
</reporting>
<distributionManagement>
<repository>
<id>apache</id>
<name>Apache Repository</name>
<url>scp://people.apache.org/www/www.apache.org/maven-repository</url>
</repository>
<snapshotRepository>
<id>apache.snapshots</id>
<name>Apache Development Repository</name>
<url>scp://people.apache.org/www/cvs.apache.org/maven-snapshot-repository</url>
</snapshotRepository>
<site>
<id>apache.site</id>
<name>Apache Website</name>
<url>scp://people.apache.org/www/ws.apache.org/ws</url>
</site>
</distributionManagement>
</project>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Questions on assembly plugin
Posted by dan tran <da...@gmail.com>.
i think the infinite loop problem it has been fixed in svn
-Dan
On 12/11/05, Arnaud Bailly <ab...@norsys.fr> wrote:
>
> I configured assembly into toplevel pom.xml for a multimodules project,
> exactly as indicated in dan tran's post and it goes into an endless
> loop !!
> Any idea about what's going on ?
> Is the assembly configuration inherited in children poms ?
> How can I make a multi-modules assembly ?
>
> Regards
> --
> Arnaud Bailly - Ingénieur de Recherche
> NORSYS
> 1, rue de la Cense des Raines
> ZAC du Moulin
> 59710 ENNEVELIN
> Tel : (33) 3 28 76 56 76
> Fax : (33) 3 28 76 57 00
> Web : http://www.norsys.fr
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>
Re: Questions on assembly plugin
Posted by Arnaud Bailly <ab...@norsys.fr>.
I configured assembly into toplevel pom.xml for a multimodules project,
exactly as indicated in dan tran's post and it goes into an endless
loop !!
Any idea about what's going on ?
Is the assembly configuration inherited in children poms ?
How can I make a multi-modules assembly ?
Regards
--
Arnaud Bailly - Ingénieur de Recherche
NORSYS
1, rue de la Cense des Raines
ZAC du Moulin
59710 ENNEVELIN
Tel : (33) 3 28 76 56 76
Fax : (33) 3 28 76 57 00
Web : http://www.norsys.fr
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Questions on assembly plugin
Posted by Brett Porter <br...@gmail.com>.
If you assigned an id to each that is different it will be ok.
- Brett
On 12/10/05, Jochen Wiedmann <jo...@gmail.com> wrote:
> dan tran wrote:
>
> > you can run maven-assembly-plugin multiple times
>
> Thanks for the hint. I may be doing something wrong, but so far it
> doesn't work. Here's what I did:
>
> - Added the "executions" section to the assembly plugins configuration.
> - Removed my existing "configuration" section.
> - Invoked "mvn assembly:assembly"
>
> Result is the following error message:
>
> POM Location: /home/jwi/workspace/ws-xmlrpc-2/pom.xml
> Validation Messages:
>
> [0] You cannot have two plugin executions with the same (or
> missing) <id/> elements.
> Offending execution
>
> Id: 'default'
> Plugin:'org.apache.maven.plugins:maven-assembly-plugin'
>
>
>
>
> Reason: Failed to validate POM
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Questions on assembly plugin
Posted by Jochen Wiedmann <jo...@gmail.com>.
dan tran wrote:
> you can run maven-assembly-plugin multiple times
Thanks for the hint. I may be doing something wrong, but so far it
doesn't work. Here's what I did:
- Added the "executions" section to the assembly plugins configuration.
- Removed my existing "configuration" section.
- Invoked "mvn assembly:assembly"
Result is the following error message:
POM Location: /home/jwi/workspace/ws-xmlrpc-2/pom.xml
Validation Messages:
[0] You cannot have two plugin executions with the same (or
missing) <id/> elements.
Offending execution
Id: 'default'
Plugin:'org.apache.maven.plugins:maven-assembly-plugin'
Reason: Failed to validate POM
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Questions on assembly plugin
Posted by dan tran <da...@gmail.com>.
you can run maven-assembly-plugin multiple times
...
<build>
...
<plugins>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<executions>
<execution>
<phase>package</phase>
<configuration>
...
</configuration>
<goals>
<goal>assembly</goal>
</goals>
</execution>
<execution>
<phase>package</phase>
<configuration> ...
</configuration>
<goals>
<goal>assembly</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
*Conclusion*
On 12/10/05, Jochen Wiedmann <jo...@gmail.com> wrote:
>
> Henry Isidro wrote:
>
> > You can override them by creating an assembly descriptor and placing bin
> > or src in the <id> tag.
>
> I see that I can specify *one* such descriptor via the plugins
> "descriptor" property. But what, if I want to override both?
>
>
> > Haven't tried this yet, but you can use executions to assemble a bin
> > then an src.
>
> What are executions?
>
>
> Regards,
>
> Jochen
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>
Re: Questions on assembly plugin
Posted by Jochen Wiedmann <jo...@gmail.com>.
Henry Isidro wrote:
> You can override them by creating an assembly descriptor and placing bin
> or src in the <id> tag.
I see that I can specify *one* such descriptor via the plugins
"descriptor" property. But what, if I want to override both?
> Haven't tried this yet, but you can use executions to assemble a bin
> then an src.
What are executions?
Regards,
Jochen
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Questions on assembly plugin
Posted by Henry Isidro <hi...@exist.com>.
Jochen Wiedmann wrote:
>Hi,
>
>I'd like to use the assembly plugin for creating distributions. After
>reading the documentation and doing some first attempts, I do have the
>following questions:
>
>- There are predefined ID's like "bin" and "src". These are (to me) very welcome
> for reading as examples. However, they do not really meet my requirements.
> I'd like to override them. Is that possible?
>
>
You can override them by creating an assembly descriptor and placing bin
or src in the <id> tag.
>- In my project I will typically always use "bin" and "src". It would
>be nice, if I
> could configure both into the POM, so that an invocation of "mvn
>assembly:assembly"
> will create these two files. However, it only seems possible to
>create a single
> file.
>
>
>
Haven't tried this yet, but you can use executions to assemble a bin
then an src.
Regards,
Henry
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org