Maven2的Plugin一覽表
Available Plugins
Maven is - at its heart - a plugin execution framework; all work is done by plugins. Looking for a specific goal to execute? This page lists the core plugins and others.
To see the most up-to-date list browse the Maven repository at http://repo1.maven.org/maven2/, specifically the org/apache/maven/plugins subfolder. (Plugins are organized according to a directory structure that resembles the standard Java package naming convention)
Plugin | Version | Description |
core plugins | Plugins corresponding to default core phases (ie. clean, compile). They may have muliple goals as well. | |
clean | 2.1.1 | Clean up after the build. |
compiler | 2.0.2 | Compiles Java sources. |
deploy | 2.3 | Deploy the built artifact to the remote repository. |
install | 2.1 | Install the built artifact into the local repository. |
resources | 2.2 | Copy the resources to the output directory for including in the JAR. |
site | 2.0-beta-5 | Generate a site for the current project. |
surefire | 2.3 | Run the Junit tests in an isolated classloader. |
verifier | 1.0-beta-1 | Useful for integration tests - verifies the existence of certain conditions. |
packaging types / tools | These plugins relate to packaging respective artifact types. | |
ear | 2.3 | Generate an EAR from the current project. |
ejb | 2.1 | Build an EJB (and optional client) from the current project. |
jar | 2.1 | Build a JAR from the current project. |
rar | 2.2 | Build a RAR from the current project. |
war | 2.0.2 | Build a WAR from the current project. |
reporting | Plugins which generate reports, are configured as reports in the POM and run under the site generation lifecycle. | |
changelog | 2.0 | Generate a list of recent changes from your SCM. |
changes | 2.0-beta-2 | Generate a report from issue tracking or a change document. |
checkstyle | 2.1 | Generate a checkstyle report. |
clover | 2.3 | Generate a Clover report. |
doap | 1.0-beta-1 | Generate a Description of a Project (DOAP) file from a POM. |
docck | 1.0-beta-1 | Documentation checker plugin. |
javadoc | 2.2 | Generate Javadoc for the project. |
jxr | 2.1 | Generate a source cross reference. |
pmd | 2.2 | Generate a PMD report. |
project-info-reports | 2.0.1 | Generate a standard project reports. |
surefire-report | 2.3 | Generate a report based on the results of unit tests. |
tools | These are miscellaneous tools available through Maven by default. | |
ant | 2.0-beta-1 | Generate an Ant build file for the project. |
antlr | 2.0-beta-1 | Generate sources from an Antlr grammar. |
antrun | 1.1 | Run a set of ant tasks from a phase of the build. |
archetype | 1.0-alpha-4 | Generate a skeleton project structure from an archetype. |
assembly | 2.2-beta-1 | Build an assembly (distribution) of sources and/or binaries. |
dependency | 2.0-alpha-4 | Dependency manipulation (copy, unpack) and analysis. |
enforcer | 1.0-alpha-1 | Environmental constraint checking (Maven Version, JDK etc). |
gpg | 1.0-alpha-3 | Create signatures for the artifacts and poms |
help | 2.0.1 | Get information about the working environment for the project. |
invoker | 1.0 | Run a set of Maven projects and verify the output |
one | 1.0 | A plugin for interacting with legacy Maven 1.x repositories and builds. |
plugin | 2.2 | Create a Maven plugin descriptor for any Mojo's found in the source tree, to include in the JAR. |
release | 2.0-beta-4 | Release the current project - updating the POM and tagging in the SCM. |
remote-resources | 1.0-alpha-4 | Copy remote resources to the output directory for inclusion in the artifact. |
repository | 2.0 | Plugin to help with repository-based tasks. |
scm | 1.0-beta-4 | Generate a SCM for the current project. |
source | 2.0.2 | Build a JAR of sources for use in IDEs and distribution to the repository. |
IDEs | Plugins that simplify integration with integrated developer environments. | |
eclipse | 2.3 | Generate an Eclipse project file for the current project. |
idea | 2.0 | Create/update an IDEA workspace for the current project (individual modules are created as IDEA modules) |
There are also many plug-ins available at the Mojo project at Codehaus. To see the most up-to-date list browse the Codehaus repository at http://repository.codehaus.org/, specifically the org/codehaus/mojo subfolder. Here are a few common ones:
Plugin | Version | Description |
build-helper | 1.0 | Attach extra artifacts and source folders to build. |
castor | 1.0 | Generate sources from an XSD using Castor. |
javacc | 2.1 | Generate sources from a JavaCC grammer. |
jdepend | 2.0-beta-1 | Generate a report on code metrics using JDepend. |
native | 1.0-alpha-2 | Compiles C and C++ code with native compilers. |
sql | 1.0 | Executes SQL scripts from files or inline. |
taglist | 2.0 | Generate a list of tasks based on tags in your code. |
A number of other projects provide their own Maven2 plugins. This includes:
Plugin | Description |
cargo | Start/stop/configure J2EE containers and deploy to them. |
jaxme | Use the JaxMe JAXB implementation to generate Java sources from XML schema. |
jetty | Run a Jetty container for rapid webapp development. |
jalopy | Use Jalopy to format your source code |
posted on 2007-06-03 18:55 MingIsMe 閱讀(1361) 評論(0) 編輯 收藏 所屬分類: 15 敏捷開發