blob: d8a4c52d93650936643afcc4b0b8ee592cd82394 [file] [log] [blame]
------
Predefined Assembly Descriptors
------
Johnny R. Ruiz III <jruiz@exist.com>
Edwin Punzalan
------
21 July 2006
~~ Copyright 2006 The Apache Software Foundation.
~~
~~ Licensed under the Apache License, Version 2.0 (the "License");
~~ you may not use this file except in compliance with the License.
~~ You may obtain a copy of the License at
~~
~~ http://www.apache.org/licenses/LICENSE-2.0
~~
~~ Unless required by applicable law or agreed to in writing, software
~~ distributed under the License is distributed on an "AS IS" BASIS,
~~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~~ See the License for the specific language governing permissions and
~~ limitations under the License.
~~ NOTE: For help with the syntax of this file, see:
~~ http://maven.apache.org/guides/mini/guide-apt-format.html
Pre-defined Descriptor Files
There are three predefined descriptor formats available for reuse, packaged
within the Assembly Plugin. Their descriptorIds are:
* {{{#bin}bin}} - can be used for general assembly of binary packages.
* {{{#jar-with-dependencies}jar-with-dependencies}} - can be used for general
assembly of a binary package with all the dependency libraries included
unpacked inside the archive.
* {{{#src}src}} - can be used for general assembly of a source archive which can
be used to build your project.
* {bin}
Use <<<bin>>> as the <<<descriptorId>>> of your assembly to create a binary
distribution archive of your project. The <<<bin>>> descriptorId produces
the archive in three formats: tar.gz, tar.bz2, and zip.
The assembled archive contains the binary jar produced by running
<<<mvn package>>> plus any README, LICENSE, and NOTICE files available in the
project root directory.
Below is the <<<bin>>> descriptor format:
-----
<assembly>
<id>bin</id>
<formats>
<format>tar.gz</format>
<format>tar.bz2</format>
<format>zip</format>
</formats>
<fileSets>
<fileSet>
<includes>
<include>README*</include>
<include>LICENSE*</include>
<include>NOTICE*</include>
</includes>
</fileSet>
<fileSet>
<directory>target</directory>
<outputDirectory></outputDirectory>
<includes>
<include>*.jar</include>
</includes>
</fileSet>
</fileSets>
</assembly>
------
* {jar-with-dependencies}
Use the <<<jar-with-dependencies>>> as the <<<descriptorId>>> of your assembly
to create a jar archive which contains the binary output of your project along
with the unpacked dependencies. The <<<jar-with-dependencies>>> descriptorId
produces one archive in jar format.
Below is the <<<jar-with-dependencies>>> descriptor format:
-----
<assembly>
<id>jar-with-dependencies</id>
<formats>
<format>jar</format>
</formats>
<includeBaseDirectory>false</includeBaseDirectory>
<dependencySets>
<dependencySet>
<outputDirectory>/</outputDirectory>
<unpack>true</unpack>
<scope>runtime</scope>
</dependencySet>
</dependencySets>
</assembly>
-----
* {src}
Use <<<src>>> as the <<<descriptorId>>> of your assembly to create source
archives for your project. The archive should contain enough information
for anyone to be able to build your project. The <<<src>>> descriptorId
produces the archive in three formats: tar.gz, tar.bz2, and zip.
Below is the <<<src>>> descriptor format:
-----
<assembly>
<id>src</id>
<formats>
<format>tar.gz</format>
<format>tar.bz2</format>
<format>zip</format>
</formats>
<fileSets>
<fileSet>
<includes>
<include>README*</include>
<include>LICENSE*</include>
<include>NOTICE*</include>
<include>pom.xml</include>
</includes>
</fileSet>
<fileSet>
<directory>src</directory>
</fileSet>
</fileSets>
</assembly>
-----