You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by dk...@apache.org on 2007/05/17 18:00:09 UTC
svn commit: r538986 - in /incubator/cxf/trunk: ./
codegen-plugin/src/main/java/org/apache/cxf/maven_plugin/eclipse/
codegen-plugin/src/main/java/org/apache/cxf/maven_plugin/eclipse/3.0/
codegen-plugin/src/main/java/org/apache/cxf/maven_plugin/eclipse/3...
Author: dkulp
Date: Thu May 17 09:00:08 2007
New Revision: 538986
URL: http://svn.apache.org/viewvc?view=rev&rev=538986
Log:
Cleanups to the eclipse plugin
* Put apache license header on the vm template
* Remove eclipse version number from artifact id
* Rename eclipe bundle name to "Apache CXF Plug-in" to meet Apache branding requirements
Added:
incubator/cxf/trunk/codegen-plugin/src/main/java/org/apache/cxf/maven_plugin/eclipse/3.2/
- copied from r538940, incubator/cxf/trunk/codegen-plugin/src/main/java/org/apache/cxf/maven_plugin/eclipse/3.1/
incubator/cxf/trunk/codegen-plugin/src/main/java/org/apache/cxf/maven_plugin/eclipse/3.2/MANIFEST.vm
incubator/cxf/trunk/tools/eclipse-plugin/
- copied from r538940, incubator/cxf/trunk/tools/eclipse3.1-plugin/
Removed:
incubator/cxf/trunk/codegen-plugin/src/main/java/org/apache/cxf/maven_plugin/eclipse/3.0/
incubator/cxf/trunk/codegen-plugin/src/main/java/org/apache/cxf/maven_plugin/eclipse/3.1/
incubator/cxf/trunk/codegen-plugin/src/main/java/org/apache/cxf/maven_plugin/eclipse/3.2/plugin.xml.vm
incubator/cxf/trunk/tools/eclipse3.1-plugin/
Modified:
incubator/cxf/trunk/codegen-plugin/src/main/java/org/apache/cxf/maven_plugin/eclipse/EclipsePluginMojo.java
incubator/cxf/trunk/pom.xml
incubator/cxf/trunk/tools/eclipse-plugin/pom.xml
Added: incubator/cxf/trunk/codegen-plugin/src/main/java/org/apache/cxf/maven_plugin/eclipse/3.2/MANIFEST.vm
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/codegen-plugin/src/main/java/org/apache/cxf/maven_plugin/eclipse/3.2/MANIFEST.vm?view=auto&rev=538986
==============================================================================
--- incubator/cxf/trunk/codegen-plugin/src/main/java/org/apache/cxf/maven_plugin/eclipse/3.2/MANIFEST.vm (added)
+++ incubator/cxf/trunk/codegen-plugin/src/main/java/org/apache/cxf/maven_plugin/eclipse/3.2/MANIFEST.vm Thu May 17 09:00:08 2007
@@ -0,0 +1,33 @@
+## Licensed to the Apache Software Foundation (ASF) under one
+## or more contributor license agreements. See the NOTICE file
+## distributed with this work for additional information
+## regarding copyright ownership. The ASF licenses this file
+## to you under the Apache License, Version 2.0 (the
+## "License"); you may not use this file except in compliance
+## with the License. You may obtain a copy of the License at
+##
+## http://www.apache.org/licenses/LICENSE-2.0
+##
+## Unless required by applicable law or agreed to in writing,
+## software distributed under the License is distributed on an
+## "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+## KIND, either express or implied. See the License for the
+## specific language governing permissions and limitations
+## under the License.
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: Apache CXF Plug-in
+Bundle-SymbolicName: ${GROUP_ID}; singleton:=true
+Bundle-Version: 2.0.0
+Bundle-Localization: plugin
+Export-Package: #foreach ($packageName in $exportedPackages)
+ ${packageName}#if($exportedPackages.size() != $velocityCount),#end
+
+#end
+Bundle-ClassPath: #foreach ($jarfile in $jars)
+ ${libPath}/$jarfile.name #if($jars.size() != $velocityCount),#end
+
+#end
+Eclipse-LazyStart: true
+Eclipse-RegisterBuddy: org.eclipse.stp.sc.common
+Require-Bundle: org.eclipse.stp.sc.common
\ No newline at end of file
Modified: incubator/cxf/trunk/codegen-plugin/src/main/java/org/apache/cxf/maven_plugin/eclipse/EclipsePluginMojo.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/codegen-plugin/src/main/java/org/apache/cxf/maven_plugin/eclipse/EclipsePluginMojo.java?view=diff&rev=538986&r1=538985&r2=538986
==============================================================================
--- incubator/cxf/trunk/codegen-plugin/src/main/java/org/apache/cxf/maven_plugin/eclipse/EclipsePluginMojo.java (original)
+++ incubator/cxf/trunk/codegen-plugin/src/main/java/org/apache/cxf/maven_plugin/eclipse/EclipsePluginMojo.java Thu May 17 09:00:08 2007
@@ -41,6 +41,9 @@
*/
public class EclipsePluginMojo extends AbstractMojo {
private static final String LIB_PATH = "lib";
+ private static final String ECLIPSE_VERSION = "3.2";
+
+
/**
* @parameter expression="${project}"
* @required
@@ -54,20 +57,15 @@
* @readonly
*/
Set dependencies;
-
+
/**
- * @parameter expression="${project.build.directory}/plugin.xml";
+ * @parameter expression="${project.build.directory}";
* @required
*/
- File targetFile;
-
- /**
- * @parameter expression="3.0";
- */
- String eclipseVersion;
+ File targetDir;
private String getTemplateFile(String version) {
- return "/org/apache/cxf/maven_plugin/eclipse/" + version + "/plugin.xml.vm";
+ return "/org/apache/cxf/maven_plugin/eclipse/" + version + "/MANIFEST.vm";
}
private List<File> listJars() throws Exception {
@@ -108,20 +106,16 @@
private void generatePluginXML(List<File> jars) throws Exception {
VelocityGenerator velocity = new VelocityGenerator();
- String templateFile = getTemplateFile(eclipseVersion);
-
- File outputFile = targetFile;
+ String templateFile = getTemplateFile(ECLIPSE_VERSION);
- velocity.setAttributes("ECLIPSE_VERSION", eclipseVersion);
+ velocity.setAttributes("ECLIPSE_VERSION", ECLIPSE_VERSION);
velocity.setAttributes("PLUGIN_VERSION", getVersion());
velocity.setAttributes("GROUP_ID", project.getGroupId());
velocity.setAttributes("libPath", LIB_PATH);
velocity.setAttributes("jars", jars);
- if ("3.1".equals(eclipseVersion.trim())) {
- velocity.setAttributes("exportedPackages", getExportedPackages(jars));
- outputFile = new File(targetFile.getParentFile(), "MANIFEST.MF");
- }
+ velocity.setAttributes("exportedPackages", getExportedPackages(jars));
+ File outputFile = new File(targetDir, "MANIFEST.MF");
velocity.doWrite(templateFile, FileWriterUtil.getWriter(outputFile));
}
Modified: incubator/cxf/trunk/pom.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/pom.xml?view=diff&rev=538986&r1=538985&r2=538986
==============================================================================
--- incubator/cxf/trunk/pom.xml (original)
+++ incubator/cxf/trunk/pom.xml Thu May 17 09:00:08 2007
@@ -145,7 +145,7 @@
<id>everything</id>
<modules>
<module>distribution</module>
- <module>tools/eclipse3.1-plugin</module>
+ <module>tools/eclipse-plugin</module>
</modules>
</profile>
<profile>
@@ -298,7 +298,7 @@
<id>deploy</id>
<modules>
<module>distribution</module>
- <module>tools/eclipse3.1-plugin</module>
+ <module>tools/eclipse-plugin</module>
</modules>
<build>
<defaultGoal>deploy</defaultGoal>
Modified: incubator/cxf/trunk/tools/eclipse-plugin/pom.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/eclipse-plugin/pom.xml?view=diff&rev=538986&r1=538940&r2=538986
==============================================================================
--- incubator/cxf/trunk/tools/eclipse-plugin/pom.xml (original)
+++ incubator/cxf/trunk/tools/eclipse-plugin/pom.xml Thu May 17 09:00:08 2007
@@ -19,10 +19,10 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>org.apache.cxf</groupId>
- <artifactId>cxf-eclipse3.1-plugin</artifactId>
+ <artifactId>cxf-eclipse-plugin</artifactId>
<packaging>jar</packaging>
<version>2.0-incubator-SNAPSHOT</version>
- <name>Apache CXF Eclipse 3.1 Distribution</name>
+ <name>Apache CXF Eclipse Distribution</name>
<url>http://cxf.apache.org/</url>
<parent>
@@ -153,9 +153,6 @@
<goals>
<goal>eclipseplugin</goal>
</goals>
- <configuration>
- <eclipseVersion>3.1</eclipseVersion>
- </configuration>
</execution>
</executions>
</plugin>
@@ -164,9 +161,9 @@
<scm>
- <connection>scm:svn:http://svn.apache.org/repos/asf/incubator/cxf/trunk/tools/eclipse3.1-plugin</connection>
- <developerConnection>scm:svn:https://svn.apache.org/repos/asf/incubator/cxf/trunk/tools/eclipse3.1-plugin</developerConnection>
- <url>http://svn.apache.org/viewvc/incubator/cxf/trunk/cxf-parent/cxf-eclipse3.1-plugin</url>
+ <connection>scm:svn:http://svn.apache.org/repos/asf/incubator/cxf/trunk/tools/eclipse-plugin</connection>
+ <developerConnection>scm:svn:https://svn.apache.org/repos/asf/incubator/cxf/trunk/tools/eclipse-plugin</developerConnection>
+ <url>http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/eclipse-plugin</url>
</scm>
</project>