Précédent: Using
a Plexus Component from a Maven Mojo. |
Haut: Background |
This section will show how to use a Plexus component from within a Maven mojo.
Maven Archetypes are discussed in detail here.
mvn archetype:create -DarchetypeGroupId=org.apache.maven.archetypes -DarchetypeArtifactId=maven-archetype-mojo \
-DarchetypeVersion=1.0-SNAPSHOT -DgroupId=org.codehaus.plexus -DartifactId=plexus-website-monitor-plugin
<?xml version="1.0"?>
<project>
<modelVersion>4.0.0</modelVersion>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-website-monitor-plugin</artifactId>
<packaging>maven-plugin</packaging>
<name>Maven Mojo Archetype</name>
<version>1.0-SNAPSHOT</version>
<url>http://maven.apache.org</url>
<dependencies>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-plugin-api</artifactId>
<version>2.0</version>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-website-monitor-component</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
</dependencies>
</project>
mvn eclipse:eclipse
Précédent: Using
a Plexus Component from a Maven Mojo. |
Haut: Background |