Author: brett
Date: Thu Jan  5 02:12:12 2012
New Revision: 1227443

URL: http://svn.apache.org/viewvc?rev=1227443&view=rev
Log:
[NPANDAY-279] fix the VS Installer Mojo with the new types

Added:
    incubator/npanday/trunk/plugins/maven-vsinstaller-plugin/src/main/script/
    
incubator/npanday/trunk/plugins/maven-vsinstaller-plugin/src/main/script/plexus_component_xml.groovy
      - copied, changed from r1227181, 
incubator/npanday/trunk/plugins/maven-compile-plugin/src/main/script/plexus_component_xml.groovy
Modified:
    
incubator/npanday/trunk/components/dotnet-core/src/main/groovy/npanday/lifecycle/LifecycleConfigurationGenerator.groovy
    incubator/npanday/trunk/plugins/maven-vsinstaller-plugin/pom.xml
    
incubator/npanday/trunk/plugins/maven-vsinstaller-plugin/src/main/resources/META-INF/plexus/components.xml

Modified: 
incubator/npanday/trunk/components/dotnet-core/src/main/groovy/npanday/lifecycle/LifecycleConfigurationGenerator.groovy
URL: 
http://svn.apache.org/viewvc/incubator/npanday/trunk/components/dotnet-core/src/main/groovy/npanday/lifecycle/LifecycleConfigurationGenerator.groovy?rev=1227443&r1=1227442&r2=1227443&view=diff
==============================================================================
--- 
incubator/npanday/trunk/components/dotnet-core/src/main/groovy/npanday/lifecycle/LifecycleConfigurationGenerator.groovy
 (original)
+++ 
incubator/npanday/trunk/components/dotnet-core/src/main/groovy/npanday/lifecycle/LifecycleConfigurationGenerator.groovy
 Thu Jan  5 02:12:12 2012
@@ -122,5 +122,12 @@ class LifecycleConfigurationGenerator {
                generator.configureMappings(g.buildMap(npandayVersion))
                generator.saveTo(componentsXmlFile)
        }
-       
+
+    static void persistAllTypesAndLifecycles(String npandayVersion, File 
componentsXmlFile) {
+        def componentsXml = componentsXmlFile.text
+
+        def generator = new LifecycleConfigurationGenerator(componentsXml)
+        generator.configureAllTypes()
+        generator.saveTo(componentsXmlFile)
+    }
 }

Modified: incubator/npanday/trunk/plugins/maven-vsinstaller-plugin/pom.xml
URL: 
http://svn.apache.org/viewvc/incubator/npanday/trunk/plugins/maven-vsinstaller-plugin/pom.xml?rev=1227443&r1=1227442&r2=1227443&view=diff
==============================================================================
--- incubator/npanday/trunk/plugins/maven-vsinstaller-plugin/pom.xml (original)
+++ incubator/npanday/trunk/plugins/maven-vsinstaller-plugin/pom.xml Thu Jan  5 
02:12:12 2012
@@ -51,6 +51,16 @@ under the License.
               <goal>testCompile</goal>
             </goals>
           </execution>
+          <execution>
+            <id>generate-plexus-config</id>
+            <phase>prepare-package</phase>
+            <goals>
+              <goal>execute</goal>
+            </goals>
+            <configuration>
+              
<source>file:///${pom.basedir}/src/main/script/plexus_component_xml.groovy</source>
+            </configuration>
+          </execution>
         </executions>
       </plugin>
     </plugins>

Modified: 
incubator/npanday/trunk/plugins/maven-vsinstaller-plugin/src/main/resources/META-INF/plexus/components.xml
URL: 
http://svn.apache.org/viewvc/incubator/npanday/trunk/plugins/maven-vsinstaller-plugin/src/main/resources/META-INF/plexus/components.xml?rev=1227443&r1=1227442&r2=1227443&view=diff
==============================================================================
--- 
incubator/npanday/trunk/plugins/maven-vsinstaller-plugin/src/main/resources/META-INF/plexus/components.xml
 (original)
+++ 
incubator/npanday/trunk/plugins/maven-vsinstaller-plugin/src/main/resources/META-INF/plexus/components.xml
 Thu Jan  5 02:12:12 2012
@@ -1,138 +1,23 @@
 <!--
-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.
--->
+  ~ 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.
+  -->
 <component-set>
   <components>
-    <component>
-      <role>org.apache.maven.artifact.handler.ArtifactHandler</role>
-      <role-hint>module</role-hint>
-      
<implementation>org.apache.maven.artifact.handler.DefaultArtifactHandler</implementation>
-      <configuration>
-        <extension>netmodule</extension>
-        <type>module</type>
-      </configuration>
-    </component>
-    <component>
-      <role>org.apache.maven.artifact.handler.ArtifactHandler</role>
-      <role-hint>exe.config</role-hint>
-      
<implementation>org.apache.maven.artifact.handler.DefaultArtifactHandler</implementation>
-      <configuration>
-        <extension>exe.config</extension>
-        <type>exe.config</type>
-      </configuration>
-    </component>
-    <component>
-      <role>org.apache.maven.artifact.handler.ArtifactHandler</role>
-      <role-hint>library</role-hint>
-      
<implementation>org.apache.maven.artifact.handler.DefaultArtifactHandler</implementation>
-      <configuration>
-        <extension>dll</extension>
-        <type>library</type>
-      </configuration>
-    </component>
-    <component>
-      <role>org.apache.maven.artifact.handler.ArtifactHandler</role>
-      <role-hint>winexe</role-hint>
-      
<implementation>org.apache.maven.artifact.handler.DefaultArtifactHandler</implementation>
-      <configuration>
-        <extension>exe</extension>
-        <type>winexe</type>
-      </configuration>
-    </component>
-    <component>
-      <role>org.apache.maven.artifact.handler.ArtifactHandler</role>
-      <role-hint>gac</role-hint>
-      
<implementation>org.apache.maven.artifact.handler.DefaultArtifactHandler</implementation>
-      <configuration>
-        <extension>dll</extension>
-        <type>gac</type>
-      </configuration>
-    </component>
-    <component>
-      <role>org.apache.maven.artifact.handler.ArtifactHandler</role>
-      <role-hint>gac_generic</role-hint>
-      
<implementation>org.apache.maven.artifact.handler.DefaultArtifactHandler</implementation>
-      <configuration>
-        <extension>dll</extension>
-        <type>gac_generic</type>
-      </configuration>
-    </component>
-    <component>
-      <role>org.apache.maven.artifact.handler.ArtifactHandler</role>
-      <role-hint>gac_msil</role-hint>
-      
<implementation>org.apache.maven.artifact.handler.DefaultArtifactHandler</implementation>
-      <configuration>
-        <extension>dll</extension>
-        <type>gac_msil</type>
-      </configuration>
-    </component>
-    <component>
-      <role>org.apache.maven.artifact.handler.ArtifactHandler</role>
-      <role-hint>gac_msil4</role-hint>
-      
<implementation>org.apache.maven.artifact.handler.DefaultArtifactHandler</implementation>
-      <configuration>
-        <extension>dll</extension>
-        <type>gac_msil4</type>
-      </configuration>
-    </component>
-    <component>
-      <role>org.apache.maven.artifact.handler.ArtifactHandler</role>      
-      <role-hint>gac_32</role-hint>
-      
<implementation>org.apache.maven.artifact.handler.DefaultArtifactHandler</implementation>
-      <configuration>
-        <extension>dll</extension>
-        <type>gac_32</type>
-      </configuration>
-    </component>
-    <component>
-      <role>org.apache.maven.artifact.handler.ArtifactHandler</role>      
-      <role-hint>gac_64</role-hint>
-      
<implementation>org.apache.maven.artifact.handler.DefaultArtifactHandler</implementation>
-      <configuration>
-        <extension>dll</extension>
-        <type>gac_64</type>
-      </configuration>
-    </component>       
-    <component>
-      <role>org.apache.maven.artifact.handler.ArtifactHandler</role>
-      <role-hint>nar</role-hint>
-      
<implementation>org.apache.maven.artifact.handler.DefaultArtifactHandler</implementation>
-      <configuration>
-        <type>nar</type>
-      </configuration>
-    </component>
-    <component>
-      <role>org.apache.maven.artifact.handler.ArtifactHandler</role>
-      <role-hint>netplugin</role-hint>
-      
<implementation>org.apache.maven.artifact.handler.DefaultArtifactHandler</implementation>
-      <configuration>
-        <extension>dll</extension>
-        <type>netplugin</type>
-      </configuration>
-    </component>
-    <component>
-      <role>org.apache.maven.artifact.handler.ArtifactHandler</role>
-      <role-hint>visual-studio-addin</role-hint>
-      
<implementation>org.apache.maven.artifact.handler.DefaultArtifactHandler</implementation>
-      <configuration>
-        <extension>dll</extension>
-        <type>visual-studio-addin</type>
-      </configuration>
-    </component>
+    <!-- all generated automatically  -->
   </components>
 </component-set>

Copied: 
incubator/npanday/trunk/plugins/maven-vsinstaller-plugin/src/main/script/plexus_component_xml.groovy
 (from r1227181, 
incubator/npanday/trunk/plugins/maven-compile-plugin/src/main/script/plexus_component_xml.groovy)
URL: 
http://svn.apache.org/viewvc/incubator/npanday/trunk/plugins/maven-vsinstaller-plugin/src/main/script/plexus_component_xml.groovy?p2=incubator/npanday/trunk/plugins/maven-vsinstaller-plugin/src/main/script/plexus_component_xml.groovy&p1=incubator/npanday/trunk/plugins/maven-compile-plugin/src/main/script/plexus_component_xml.groovy&r1=1227181&r2=1227443&rev=1227443&view=diff
==============================================================================
--- 
incubator/npanday/trunk/plugins/maven-compile-plugin/src/main/script/plexus_component_xml.groovy
 (original)
+++ 
incubator/npanday/trunk/plugins/maven-vsinstaller-plugin/src/main/script/plexus_component_xml.groovy
 Thu Jan  5 02:12:12 2012
@@ -16,7 +16,8 @@
  * specific language governing permissions and limitations
  * under the License.
  */
-import npanday.plugin.compile.CompileLifecycleMap
+
+
 import npanday.lifecycle.LifecycleConfigurationGenerator
 
 def plexus = new File(project.build.outputDirectory, 'META-INF/plexus')
@@ -25,4 +26,4 @@ plexus.mkdirs()
 def componentsXmlFile = new File(plexus, 'components.xml');
 
 LifecycleConfigurationGenerator
-               .persistAllTypesAndLifecycles(CompileLifecycleMap, 
project.version, componentsXmlFile)
+               .persistAllTypesAndLifecycles(project.version, 
componentsXmlFile)


Reply via email to