aboutsummaryrefslogtreecommitdiffstats
path: root/demo
diff options
context:
space:
mode:
authorDecebal Suiu <decebal.suiu@gmail.com>2012-11-05 13:58:18 +0200
committerDecebal Suiu <decebal.suiu@gmail.com>2012-11-05 13:58:18 +0200
commit363b2b093ccecfc75fd28f49ca2aa139bbc6d1ce (patch)
tree5e0dd12fd56b8ab5819c6a3449738d74fad12059 /demo
parent112b73f4eac7fbac80033589a17571198ec6133d (diff)
downloadpf4j-363b2b093ccecfc75fd28f49ca2aa139bbc6d1ce.tar.gz
pf4j-363b2b093ccecfc75fd28f49ca2aa139bbc6d1ce.zip
it seems to me that properties-maven-plugin doesn't work with maven 3
Diffstat (limited to 'demo')
-rw-r--r--demo/plugin1/pom.xml118
-rw-r--r--demo/plugin2/pom.xml56
-rw-r--r--demo/pom.xml13
3 files changed, 94 insertions, 93 deletions
diff --git a/demo/plugin1/pom.xml b/demo/plugin1/pom.xml
index 074aeca..c36948e 100644
--- a/demo/plugin1/pom.xml
+++ b/demo/plugin1/pom.xml
@@ -21,47 +21,58 @@
</license>
</licenses>
+
+ <properties>
+ <plugin.id>welcome-plugin</plugin.id>
+ <plugin.class>ro.fortsoft.pf4j.demo.welcome.WelcomePlugin</plugin.class>
+ <plugin.version>0.0.1</plugin.version>
+ <plugin.provider>Decebal Suiu</plugin.provider>
+ <plugin.dependencies></plugin.dependencies>
+ </properties>
+
<build>
<plugins>
+ <!-- DOESN'T WORK WITH MAVEN 3 (I defined the plugin metadata in properties section)
<plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>properties-maven-plugin</artifactId>
- <version>1.0-alpha-2</version>
- <executions>
- <execution>
- <phase>initialize</phase>
- <goals>
- <goal>read-project-properties</goal>
- </goals>
- <configuration>
- <files>
- <file>plugin.properties</file>
- </files>
- </configuration>
- </execution>
- </executions>
- </plugin>
-
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-antrun-plugin</artifactId>
- <version>1.6</version>
- <executions>
- <execution>
- <id>unzip jar file</id>
- <phase>package</phase>
- <configuration>
- <target>
- <unzip src="target/${artifactId}-${version}.${packaging}" dest="target/plugin-classes" />
- </target>
- </configuration>
- <goals>
- <goal>run</goal>
- </goals>
- </execution>
- </executions>
- </plugin>
-
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>properties-maven-plugin</artifactId>
+ <version>1.0-alpha-2</version>
+ <executions>
+ <execution>
+ <phase>initialize</phase>
+ <goals>
+ <goal>read-project-properties</goal>
+ </goals>
+ <configuration>
+ <files>
+ <file>plugin.properties</file>
+ </files>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ -->
+
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-antrun-plugin</artifactId>
+ <version>1.6</version>
+ <executions>
+ <execution>
+ <id>unzip jar file</id>
+ <phase>package</phase>
+ <configuration>
+ <target>
+ <unzip src="target/${artifactId}-${version}.${packaging}" dest="target/plugin-classes" />
+ </target>
+ </configuration>
+ <goals>
+ <goal>run</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<version>2.3</version>
@@ -84,21 +95,22 @@
</executions>
</plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-jar-plugin</artifactId>
- <configuration>
- <archive>
- <manifestEntries>
- <Plugin-Id>${plugin.id}</Plugin-Id>
- <Plugin-Class>${plugin.class}</Plugin-Class>
- <Plugin-Version>${plugin.version}</Plugin-Version>
- <Plugin-Provider>${plugin.provider}</Plugin-Provider>
- <Plugin-Dependencies>${plugin.dependencies}</Plugin-Dependencies>
- </manifestEntries>
- </archive>
- </configuration>
- </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-jar-plugin</artifactId>
+ <version>2.4</version>
+ <configuration>
+ <archive>
+ <manifestEntries>
+ <Plugin-Id>${plugin.id}</Plugin-Id>
+ <Plugin-Class>${plugin.class}</Plugin-Class>
+ <Plugin-Version>${plugin.version}</Plugin-Version>
+ <Plugin-Provider>${plugin.provider}</Plugin-Provider>
+ <Plugin-Dependencies>${plugin.dependencies}</Plugin-Dependencies>
+ </manifestEntries>
+ </archive>
+ </configuration>
+ </plugin>
<plugin>
<artifactId>maven-deploy-plugin</artifactId>
diff --git a/demo/plugin2/pom.xml b/demo/plugin2/pom.xml
index 1b393a6..3b65ea6 100644
--- a/demo/plugin2/pom.xml
+++ b/demo/plugin2/pom.xml
@@ -20,27 +20,37 @@
<distribution>repo</distribution>
</license>
</licenses>
+
+ <properties>
+ <plugin.id>hello-plugin</plugin.id>
+ <plugin.class>ro.fortsoft.pf4j.demo.hello.HelloPlugin</plugin.class>
+ <plugin.version>0.0.1</plugin.version>
+ <plugin.provider>Decebal Suiu</plugin.provider>
+ <plugin.dependencies></plugin.dependencies>
+ </properties>
<build>
<plugins>
+ <!-- DOESN'T WORK WITH MAVEN 3 (I defined the plugin metadata in properties section)
<plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>properties-maven-plugin</artifactId>
- <version>1.0-alpha-2</version>
- <executions>
- <execution>
- <phase>initialize</phase>
- <goals>
- <goal>read-project-properties</goal>
- </goals>
- <configuration>
- <files>
- <file>plugin.properties</file>
- </files>
- </configuration>
- </execution>
- </executions>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>properties-maven-plugin</artifactId>
+ <version>1.0-alpha-2</version>
+ <executions>
+ <execution>
+ <phase>initialize</phase>
+ <goals>
+ <goal>read-project-properties</goal>
+ </goals>
+ <configuration>
+ <files>
+ <file>plugin.properties</file>
+ </files>
+ </configuration>
+ </execution>
+ </executions>
</plugin>
+ -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
@@ -66,28 +76,19 @@
<artifactId>maven-assembly-plugin</artifactId>
<version>2.3</version>
<configuration>
- <appendAssemblyId>false</appendAssemblyId>
<descriptors>
<descriptor>
src/main/assembly/assembly.xml
</descriptor>
</descriptors>
- <archive>
- <manifestEntries>
- <Plugin-Id>${plugin.id}</Plugin-Id>
- <Plugin-Class>${plugin.class}</Plugin-Class>
- <Plugin-Version>${plugin.version}</Plugin-Version>
- <Plugin-Provider>${plugin.provider}</Plugin-Provider>
- <Plugin-Dependencies>${plugin.dependencies}</Plugin-Dependencies>
- </manifestEntries>
- </archive>
+ <appendAssemblyId>false</appendAssemblyId>
</configuration>
<executions>
<execution>
<id>make-assembly</id>
<phase>package</phase>
<goals>
- <goal>single</goal>
+ <goal>attached</goal>
</goals>
</execution>
</executions>
@@ -96,6 +97,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
+ <version>2.4</version>
<configuration>
<archive>
<manifestEntries>
diff --git a/demo/pom.xml b/demo/pom.xml
index 6171fad..fa8bb3a 100644
--- a/demo/pom.xml
+++ b/demo/pom.xml
@@ -35,19 +35,6 @@
<directory>src/main/resources</directory>
</resource>
</resources>
-
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <version>2.3.2</version>
- <configuration>
- <source>1.6</source>
- <target>1.6</target>
- <optimize>true</optimize>
- </configuration>
- </plugin>
- </plugins>
</build>
<modules>