Package org.glassfish.build
Class ZipMojo
java.lang.Object
org.apache.maven.plugin.AbstractMojo
org.glassfish.build.ZipMojo
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled
,org.apache.maven.plugin.Mojo
@Mojo(name="zip",
requiresDependencyResolution=RUNTIME,
defaultPhase=PACKAGE,
requiresProject=true)
public final class ZipMojo
extends org.apache.maven.plugin.AbstractMojo
Creates a zip file.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static final class
ArtifactHandler
implementation. -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate Boolean
Attach the produced artifact.private File
The root directory of the default FileSet.private String
behavior when a duplicate file is found.private String
Comma or space separated list of exclude patterns.private String
The extension of the generated file.private org.apache.tools.ant.types.ZipFileSet[]
Content to include in the zip.private String
The file name of the created zip.private String
Comma or space separated list of include patterns.private File
The directory where the zip will be created.private org.apache.maven.project.MavenProject
The maven project.private static final String
Parameters property prefix.Fields inherited from interface org.apache.maven.plugin.Mojo
ROLE
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class org.apache.maven.plugin.AbstractMojo
getLog, getPluginContext, setLog, setPluginContext
-
Field Details
-
PROPERTY_PREFIX
Parameters property prefix.- See Also:
-
project
@Parameter(defaultValue="${project}", required=true, readonly=true) private org.apache.maven.project.MavenProject projectThe maven project. -
outputDirectory
@Parameter(property="gfzip.outputDirectoryoutputDirectory", defaultValue="${project.build.directory}") private File outputDirectoryThe directory where the zip will be created. -
finalName
@Parameter(property="gfzip.outputDirectoryfinalName", defaultValue="${project.build.finalName}") private String finalNameThe file name of the created zip. -
duplicate
behavior when a duplicate file is found. Valid values are "add", "preserve", and "fail" ; default value is "add" -
filesets
@Parameter(property="gfzip.outputDirectoryfilesets") private org.apache.tools.ant.types.ZipFileSet[] filesetsContent to include in the zip. -
dir
@Parameter(property="gfzip.outputDirectorydir", defaultValue="${project.build.directory}") private File dirThe root directory of the default FileSet. Only when no fileset(s) provided. -
includes
Comma or space separated list of include patterns. all files are included when omitted ; Only when no fileset provided. -
excludes
Comma or space separated list of exclude patterns. all files are included when omitted ; Only when no fileset provided. -
extension
The extension of the generated file. -
attach
Attach the produced artifact.
-
-
Constructor Details
-
ZipMojo
public ZipMojo()
-
-
Method Details
-
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
-