eu.lindenbaum.maven
Class PackageMojo
java.lang.Object
org.apache.maven.plugin.AbstractMojo
eu.lindenbaum.maven.PackageMojo
- All Implemented Interfaces:
- org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo
public final class PackageMojo
- extends org.apache.maven.plugin.AbstractMojo
This Mojo
packages all application artifacts into a single
.tar.gz
package. This includes .beam
files, the .hrl
include files, SNMP resources, private data from the priv
and
resources
directories and non-erlang sources.
Besides that this Mojo
also copies the erlang application resource
file. In order to manage the project over the project pom there is the
possibility to let the Mojo
automatically fill in values from the
project pom into the .app
file. This can be done by using one of the
supported variables into the application resource files. Below is a list of
supported variables and their substitutions:
${ARTIFACT}
: the projects artifact id (atom)
${DESCRIPTION}
: the projects description (string)
${ID}
: the projects id (string)
${VERSION}
: the projects version (string)
${MODULES}
: all compiled .beam
files found in the
target ebin folder (list)
${REGISTERED}
: all registered names, based on the
-registered(Names).
attribute retrieved from the compiled
.beam
files (list)
In case there is no application resouce file specified the Mojo
will
generate a default .app
file which looks like this:
{application, ${ARTIFACT},
[{description, ${DESCRIPTION}},
{id, ${ID}},
{vsn, ${VERSION}},
{modules, ${MODULES}},
{maxT, infinity},
{registered, ${REGISTERED}},
{included_applications, []},
{applications, []},
{env, []},
{mod, undefined},
{start_phases, []}]}.
The resulting application resource file as well as the application upgrade
file will be checked for plausability regardless if generated or not. This is
done by checking the application version against the project version,
checking the application modules against the found compiled modules as well
as checking the application's start module.
- Author:
- Olivier Sambourg, Tobias Schlager , Olle Törnström
Fields inherited from interface org.apache.maven.plugin.Mojo |
ROLE |
Methods inherited from class org.apache.maven.plugin.AbstractMojo |
getLog, getPluginContext, setLog, setPluginContext |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PackageMojo
public PackageMojo()
execute
public void execute()
throws org.apache.maven.plugin.MojoExecutionException,
org.apache.maven.plugin.MojoFailureException
- Throws:
org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoFailureException
Copyright © 2010 Lindenbaum GmbH. All Rights Reserved.