geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jdil...@apache.org
Subject svn commit: r452770 - in /geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main: java/org/apache/geronimo/plugin/car/ resources/META-INF/plexus/
Date Wed, 04 Oct 2006 07:02:23 GMT
Author: jdillon
Date: Wed Oct  4 00:02:22 2006
New Revision: 452770

URL: http://svn.apache.org/viewvc?view=rev&rev=452770
Log:
Adding new geronimo-module packaging
starting to refactor to remove the need to override maven's dependency scope to apply custom
import types

Added:
    geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/plugin/car/ImportConfig.java
  (with props)
Modified:
    geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/plugin/car/InstallConfigMojo.java
    geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/plugin/car/PackageMojo.java
    geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/resources/META-INF/plexus/components.xml

Added: geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/plugin/car/ImportConfig.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/plugin/car/ImportConfig.java?view=auto&rev=452770
==============================================================================
--- geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/plugin/car/ImportConfig.java
(added)
+++ geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/plugin/car/ImportConfig.java
Wed Oct  4 00:02:22 2006
@@ -0,0 +1,32 @@
+/*
+ * 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.
+ */
+
+package org.apache.geronimo.plugin.car;
+
+import org.apache.geronimo.genesis.ArtifactItem;
+
+/**
+ * ???
+ *
+ * @version $Rev:385659 $ $Date$
+ */
+public class ImportConfig
+    extends ArtifactItem
+{
+}

Propchange: geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/plugin/car/ImportConfig.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/plugin/car/ImportConfig.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/plugin/car/ImportConfig.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Modified: geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/plugin/car/InstallConfigMojo.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/plugin/car/InstallConfigMojo.java?view=diff&rev=452770&r1=452769&r2=452770
==============================================================================
--- geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/plugin/car/InstallConfigMojo.java
(original)
+++ geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/plugin/car/InstallConfigMojo.java
Wed Oct  4 00:02:22 2006
@@ -232,12 +232,12 @@
             // Copy the artifact into the target repo
             if (!targetRepo.contains(configArtifact)) {
                 File sourceFile = sourceRepo.getLocation(configArtifact);
-                InputStream in = new BufferedInputStream(new FileInputStream(sourceFile));
+                InputStream input = new BufferedInputStream(new FileInputStream(sourceFile));
                 try {
-                    targetRepo.copyToRepository(in, (int)sourceFile.length(), configArtifact,
monitor);
+                    targetRepo.copyToRepository(input, (int)sourceFile.length(), configArtifact,
monitor);
                 }
                 finally {
-                    in.close();
+                    input.close();
                 }
             }
 

Modified: geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/plugin/car/PackageMojo.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/plugin/car/PackageMojo.java?view=diff&rev=452770&r1=452769&r2=452770
==============================================================================
--- geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/plugin/car/PackageMojo.java
(original)
+++ geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/plugin/car/PackageMojo.java
Wed Oct  4 00:02:22 2006
@@ -62,10 +62,6 @@
 /**
  * Build a Geronimo Configuration using the local Maven infrastructure.
  *
- * <p>
- * <b>NOTE:</b> Calling pom.xml must have defined a ${geronimoVersion} property.
- * </p>
- *
  * @goal package
  * @requiresDependencyResolution runtime
  *
@@ -82,7 +78,16 @@
      * @parameter
      */
     private MavenArchiveConfiguration archive = new MavenArchiveConfiguration();
-
+    
+    /**
+     * Require <tt>geronimoVersion</tt> property to be set.
+     *
+     * @parameter expression="${geronimoVersion}"
+     * @required
+     * @readonly
+     */
+    private String geronimoVersion = null;
+    
     /**
      * The Jar archiver.
      *

Modified: geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/resources/META-INF/plexus/components.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/resources/META-INF/plexus/components.xml?view=diff&rev=452770&r1=452769&r2=452770
==============================================================================
--- geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/resources/META-INF/plexus/components.xml
(original)
+++ geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/resources/META-INF/plexus/components.xml
Wed Oct  4 00:02:22 2006
@@ -22,6 +22,7 @@
 
 <component-set>
     <components>
+        
         <component>
             <role>org.apache.maven.lifecycle.mapping.LifecycleMapping</role>
             <role-hint>car</role-hint>
@@ -35,6 +36,30 @@
                 </phases>
             </configuration>
         </component>
+        
+        <!--
+        Custom packaging for geronimo modules.
+        -->
+        <component>
+            <role>org.apache.maven.lifecycle.mapping.LifecycleMapping</role>
+            <role-hint>geronimo-module</role-hint>
+            <implementation>org.apache.maven.lifecycle.mapping.DefaultLifecycleMapping</implementation>
+            <configuration>
+                <lifecycles>
+                    <lifecycle>
+                        <id>default</id>
+                        <phases>
+                            <process-resources>org.apache.maven.plugins:maven-resources-plugin:resources</process-resources>
+                            <compile>org.apache.geronimo.plugins:car-maven-plugin:prepare-plan</compile>
+                            <package>org.apache.geronimo.plugins:car-maven-plugin:package</package>
+                            <install>org.apache.maven.plugins:maven-install-plugin:install</install>
+                            <deploy>org.apache.maven.plugins:maven-deploy-plugin:deploy</deploy>
+                        </phases>
+                    </lifecycle>
+                </lifecycles>
+            </configuration>
+        </component>
+        
     </components>
 </component-set>
 



Mime
View raw message