Custom Maven Assembly Descriptors: Difference between revisions

From NovaOrdis Knowledge Base
Jump to navigation Jump to search
(Created page with " Maven offers a set of predefined assembly descriptors, described below. Custom assembly descriptors can also be created, and this is the reference documentation for a custom...")
 
No edit summary
Line 1: Line 1:
=External=


Maven offers a set of predefined assembly descriptors, described below. Custom assembly descriptors can also be created, and this is the reference documentation for a custom assembly descriptor:
* Custom assembly descriptor reference http://maven.apache.org/components/plugins/maven-assembly-plugin/assembly.html


<blockquote style="background-color: AliceBlue; border: solid thin LightSteelBlue;">
=Internal=
:http://maven.apache.org/components/plugins/maven-assembly-plugin/assembly.html<br>
 
</blockquote>
* [[Maven_assembly_Plugin#Custom_Assembly_Descriptors|Maven assembly Plugin]]
 
=Overview=
 
Custom assembly descriptors are conventionally placed under <tt>src/assembly</tt> of the module that executes the plugin.
 
=Example=


This is an example of a custom assembly descriptor, used to build a [[Building_a_Maven_Complex_Release_Artifact#Custom_Assembly_File|complex release artifact for a multi-module project]]:  
This is an example of a custom assembly descriptor, used to build a [[Building_a_Maven_Complex_Release_Artifact#Custom_Assembly_File|complex release artifact for a multi-module project]]:  
Line 12: Line 19:
</blockquote>
</blockquote>


Custom assembly descriptors are conventionally placed under <tt>src/assembly</tt> of the module that executes the plugin.
=Elements=


===Assembly ID===
==Assembly ID==


The assembly ID is specified as the value of the <id> element in the assembly descriptor. The assembly ID will become the assembly artifact classifier, present between the version and the extension. The artifact will be named <project-name>-<assemblyId>.<ext>. If I just want it to be <project-name>.<ext> (or <final-name>.<ext>), do not use an <id>...</id> declaration in the assembly descriptor.
The assembly ID is specified as the value of the <id> element in the assembly descriptor. The assembly ID will become the assembly artifact classifier, present between the version and the extension. The artifact will be named <project-name>-<assemblyId>.<ext>. If I just want it to be <project-name>.<ext> (or <final-name>.<ext>), do not use an <id>...</id> declaration in the assembly descriptor.

Revision as of 18:55, 7 November 2016

External

Internal

Overview

Custom assembly descriptors are conventionally placed under src/assembly of the module that executes the plugin.

Example

This is an example of a custom assembly descriptor, used to build a complex release artifact for a multi-module project:

Custom Maven Assembly Descriptor Example

Elements

Assembly ID

The assembly ID is specified as the value of the <id> element in the assembly descriptor. The assembly ID will become the assembly artifact classifier, present between the version and the extension. The artifact will be named <project-name>-<assemblyId>.<ext>. If I just want it to be <project-name>.<ext> (or <final-name>.<ext>), do not use an <id>...</id> declaration in the assembly descriptor.