https://github.com/wildfly/wildfly-zip-plugin
Provides Plexus components to support 'zip' as a Maven packaging type
https://github.com/wildfly/wildfly-zip-plugin
Last synced: about 1 year ago
JSON representation
Provides Plexus components to support 'zip' as a Maven packaging type
- Host: GitHub
- URL: https://github.com/wildfly/wildfly-zip-plugin
- Owner: wildfly
- License: apache-2.0
- Created: 2025-05-20T15:27:14.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-07-14T22:00:49.000Z (about 1 year ago)
- Last Synced: 2025-07-15T01:09:18.470Z (about 1 year ago)
- Language: Java
- Size: 22.5 KB
- Stars: 0
- Watchers: 8
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# wildfly-zip-plugin
Provides Plexus components to support 'zip' as a Maven packaging type. Provides a Maven mojo to attach a configured zip file to the project as the main artifact.
A typical use case for this would be a maven module that uses the `maven-assembly-plugin` to produce a zip, and that zip is the primary output of the module.
This project is primarily a workaround to an issue where `nxrm3-maven-plugin` was having problems dealing with `pom` packaging projects that attached a zip to the project with no Maven classifier. Using this plugin allows the packaging to be `zip` and for the zip file to be used as the main artifact of the module.
# Usage
Imagine a project where `maven-assembly-plugin` or some other tool produces a zip in the `target` dir with a file name equivalent to `${project.artifactId}-${project.version}.zip`. Using this plugin would look like this:
```
....
com.example
foo-zip
zip
....
org.wildfly.plugins
wildfly-zip-plugin
${version.org.wildfly.plugins.wildfly-zip-plugin}
true
org.apache.maven.plugins
maven-assembly-plugin
default-single
prepare-package
....
false
false
....
```
The project provides a `package` mojo that attaches a specified file as the project's main artifact. It supports two configuration options:
* `artifact-directory` -- directory where the artifact is located. Defaults to `${project.build.directory}`.
* `artifact-name` -- file name of the artifact. Defaults to `${project.artifactId}-${project.version}.zip`
When the plugin is used as a maven extension (`true` in the plugin declaration), a `default-package` maven execution will run the `package` goal in the `package` phase.