geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jdil...@apache.org
Subject svn commit: r573330 [2/2] - in /geronimo/sandbox/gshell/trunk: ./ gshell-ansi/src/main/resources/org/ gshell-ansi/src/site/ gshell-ansi/src/site/apt/ gshell-api/src/main/java/org/apache/geronimo/gshell/command/ gshell-api/src/main/java/org/apache/geron...
Date Thu, 06 Sep 2007 18:20:56 GMT
Modified: geronimo/sandbox/gshell/trunk/gshell-core/src/test/java/org/apache/geronimo/gshell/VariablesImplTest.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/gshell-core/src/test/java/org/apache/geronimo/gshell/VariablesImplTest.java?rev=573330&r1=573329&r2=573330&view=diff
==============================================================================
--- geronimo/sandbox/gshell/trunk/gshell-core/src/test/java/org/apache/geronimo/gshell/VariablesImplTest.java (original)
+++ geronimo/sandbox/gshell/trunk/gshell-core/src/test/java/org/apache/geronimo/gshell/VariablesImplTest.java Thu Sep  6 11:20:42 2007
@@ -34,47 +34,6 @@
 public class VariablesImplTest
     extends TestCase
 {
-    public void testConstructorArgsNull() throws Exception {
-        try {
-            new VariablesImpl((Map<String,Object>)null);
-            fail("Accepted a null value");
-        }
-        catch (AssertionError expected) {
-            // ignore
-        }
-
-        try {
-            new VariablesImpl((Variables)null);
-            fail("Accepted a null value");
-        }
-        catch (AssertionError expected) {
-            // ignore
-        }
-
-        try {
-            new VariablesImpl(new HashMap<String,Object>(), null);
-            fail("Accepted a null value");
-        }
-        catch (AssertionError expected) {
-            // ignore
-        }
-
-        // Happy day
-        new VariablesImpl(new HashMap<String,Object>(), new VariablesImpl());
-    }
-
-    /*
-    public void testSetNameIsNull() throws Exception {
-        try {
-            new VariablesImpl().set(null, null);
-            fail("Accepted a null value");
-        }
-        catch (IllegalArgumentException expected) {
-            // ignore
-        }
-    }
-    */
-
     public void testSet() throws Exception {
         VariablesImpl vars = new VariablesImpl();
         String name = "a";

Modified: geronimo/sandbox/gshell/trunk/gshell-layout/src/main/java/org/apache/geronimo/gshell/layout/LayoutManagerImpl.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/gshell-layout/src/main/java/org/apache/geronimo/gshell/layout/LayoutManagerImpl.java?rev=573330&r1=573329&r2=573330&view=diff
==============================================================================
--- geronimo/sandbox/gshell/trunk/gshell-layout/src/main/java/org/apache/geronimo/gshell/layout/LayoutManagerImpl.java (original)
+++ geronimo/sandbox/gshell/trunk/gshell-layout/src/main/java/org/apache/geronimo/gshell/layout/LayoutManagerImpl.java Thu Sep  6 11:20:42 2007
@@ -28,7 +28,7 @@
 import com.thoughtworks.xstream.XStream;
 import com.thoughtworks.xstream.annotations.Annotations;
 import com.thoughtworks.xstream.io.xml.DomDriver;
-import org.apache.geronimo.gshell.command.Environment;
+import org.apache.geronimo.gshell.command.ShellInfo;
 import org.apache.geronimo.gshell.layout.model.Alias;
 import org.apache.geronimo.gshell.layout.model.Command;
 import org.apache.geronimo.gshell.layout.model.Layout;
@@ -51,16 +51,16 @@
     private final Logger log = LoggerFactory.getLogger(getClass());
     
     @Requirement
-    private Environment env;
+    private ShellInfo info;
 
     private Layout layout;
     
     public void initialize() throws InitializationException {
-        assert env != null;
+        assert info != null;
 
         URL url = null;
         try {
-            url = new File(env.getHomeDir(), "etc/layout.xml").toURI().toURL();
+            url = new File(info.getHomeDir(), "etc/layout.xml").toURI().toURL();
         } catch (MalformedURLException e) {
             throw new InitializationException("Invalid URL for layout configuration", e);
         }

Modified: geronimo/sandbox/gshell/trunk/gshell-layout/src/main/java/org/apache/geronimo/gshell/layout/model/Command.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/gshell-layout/src/main/java/org/apache/geronimo/gshell/layout/model/Command.java?rev=573330&r1=573329&r2=573330&view=diff
==============================================================================
--- geronimo/sandbox/gshell/trunk/gshell-layout/src/main/java/org/apache/geronimo/gshell/layout/model/Command.java (original)
+++ geronimo/sandbox/gshell/trunk/gshell-layout/src/main/java/org/apache/geronimo/gshell/layout/model/Command.java Thu Sep  6 11:20:42 2007
@@ -30,6 +30,11 @@
 public class Command
     extends Node
 {
+    //
+    // FIXME: This isn't really goning to be the implementation, but its a key to reference a command which has been discovered previously
+    //        So, rename this shizzz
+    //
+    
     protected String implementation;
 
     public Command(final String name, final String implementation) {

Added: geronimo/sandbox/gshell/trunk/gshell-maven-plugin/LICENSE.txt
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/gshell-maven-plugin/LICENSE.txt?rev=573330&view=auto
==============================================================================
--- geronimo/sandbox/gshell/trunk/gshell-maven-plugin/LICENSE.txt (added)
+++ geronimo/sandbox/gshell/trunk/gshell-maven-plugin/LICENSE.txt Thu Sep  6 11:20:42 2007
@@ -0,0 +1,203 @@
+
+                                 Apache License
+                           Version 2.0, January 2004
+                        http://www.apache.org/licenses/
+
+   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+   1. Definitions.
+
+      "License" shall mean the terms and conditions for use, reproduction,
+      and distribution as defined by Sections 1 through 9 of this document.
+
+      "Licensor" shall mean the copyright owner or entity authorized by
+      the copyright owner that is granting the License.
+
+      "Legal Entity" shall mean the union of the acting entity and all
+      other entities that control, are controlled by, or are under common
+      control with that entity. For the purposes of this definition,
+      "control" means (i) the power, direct or indirect, to cause the
+      direction or management of such entity, whether by contract or
+      otherwise, or (ii) ownership of fifty percent (50%) or more of the
+      outstanding shares, or (iii) beneficial ownership of such entity.
+
+      "You" (or "Your") shall mean an individual or Legal Entity
+      exercising permissions granted by this License.
+
+      "Source" form shall mean the preferred form for making modifications,
+      including but not limited to software source code, documentation
+      source, and configuration files.
+
+      "Object" form shall mean any form resulting from mechanical
+      transformation or translation of a Source form, including but
+      not limited to compiled object code, generated documentation,
+      and conversions to other media types.
+
+      "Work" shall mean the work of authorship, whether in Source or
+      Object form, made available under the License, as indicated by a
+      copyright notice that is included in or attached to the work
+      (an example is provided in the Appendix below).
+
+      "Derivative Works" shall mean any work, whether in Source or Object
+      form, that is based on (or derived from) the Work and for which the
+      editorial revisions, annotations, elaborations, or other modifications
+      represent, as a whole, an original work of authorship. For the purposes
+      of this License, Derivative Works shall not include works that remain
+      separable from, or merely link (or bind by name) to the interfaces of,
+      the Work and Derivative Works thereof.
+
+      "Contribution" shall mean any work of authorship, including
+      the original version of the Work and any modifications or additions
+      to that Work or Derivative Works thereof, that is intentionally
+      submitted to Licensor for inclusion in the Work by the copyright owner
+      or by an individual or Legal Entity authorized to submit on behalf of
+      the copyright owner. For the purposes of this definition, "submitted"
+      means any form of electronic, verbal, or written communication sent
+      to the Licensor or its representatives, including but not limited to
+      communication on electronic mailing lists, source code control systems,
+      and issue tracking systems that are managed by, or on behalf of, the
+      Licensor for the purpose of discussing and improving the Work, but
+      excluding communication that is conspicuously marked or otherwise
+      designated in writing by the copyright owner as "Not a Contribution."
+
+      "Contributor" shall mean Licensor and any individual or Legal Entity
+      on behalf of whom a Contribution has been received by Licensor and
+      subsequently incorporated within the Work.
+
+   2. Grant of Copyright License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      copyright license to reproduce, prepare Derivative Works of,
+      publicly display, publicly perform, sublicense, and distribute the
+      Work and such Derivative Works in Source or Object form.
+
+   3. Grant of Patent License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      (except as stated in this section) patent license to make, have made,
+      use, offer to sell, sell, import, and otherwise transfer the Work,
+      where such license applies only to those patent claims licensable
+      by such Contributor that are necessarily infringed by their
+      Contribution(s) alone or by combination of their Contribution(s)
+      with the Work to which such Contribution(s) was submitted. If You
+      institute patent litigation against any entity (including a
+      cross-claim or counterclaim in a lawsuit) alleging that the Work
+      or a Contribution incorporated within the Work constitutes direct
+      or contributory patent infringement, then any patent licenses
+      granted to You under this License for that Work shall terminate
+      as of the date such litigation is filed.
+
+   4. Redistribution. You may reproduce and distribute copies of the
+      Work or Derivative Works thereof in any medium, with or without
+      modifications, and in Source or Object form, provided that You
+      meet the following conditions:
+
+      (a) You must give any other recipients of the Work or
+          Derivative Works a copy of this License; and
+
+      (b) You must cause any modified files to carry prominent notices
+          stating that You changed the files; and
+
+      (c) You must retain, in the Source form of any Derivative Works
+          that You distribute, all copyright, patent, trademark, and
+          attribution notices from the Source form of the Work,
+          excluding those notices that do not pertain to any part of
+          the Derivative Works; and
+
+      (d) If the Work includes a "NOTICE" text file as part of its
+          distribution, then any Derivative Works that You distribute must
+          include a readable copy of the attribution notices contained
+          within such NOTICE file, excluding those notices that do not
+          pertain to any part of the Derivative Works, in at least one
+          of the following places: within a NOTICE text file distributed
+          as part of the Derivative Works; within the Source form or
+          documentation, if provided along with the Derivative Works; or,
+          within a display generated by the Derivative Works, if and
+          wherever such third-party notices normally appear. The contents
+          of the NOTICE file are for informational purposes only and
+          do not modify the License. You may add Your own attribution
+          notices within Derivative Works that You distribute, alongside
+          or as an addendum to the NOTICE text from the Work, provided
+          that such additional attribution notices cannot be construed
+          as modifying the License.
+
+      You may add Your own copyright statement to Your modifications and
+      may provide additional or different license terms and conditions
+      for use, reproduction, or distribution of Your modifications, or
+      for any such Derivative Works as a whole, provided Your use,
+      reproduction, and distribution of the Work otherwise complies with
+      the conditions stated in this License.
+
+   5. Submission of Contributions. Unless You explicitly state otherwise,
+      any Contribution intentionally submitted for inclusion in the Work
+      by You to the Licensor shall be under the terms and conditions of
+      this License, without any additional terms or conditions.
+      Notwithstanding the above, nothing herein shall supersede or modify
+      the terms of any separate license agreement you may have executed
+      with Licensor regarding such Contributions.
+
+   6. Trademarks. This License does not grant permission to use the trade
+      names, trademarks, service marks, or product names of the Licensor,
+      except as required for reasonable and customary use in describing the
+      origin of the Work and reproducing the content of the NOTICE file.
+
+   7. Disclaimer of Warranty. Unless required by applicable law or
+      agreed to in writing, Licensor provides the Work (and each
+      Contributor provides its Contributions) on an "AS IS" BASIS,
+      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+      implied, including, without limitation, any warranties or conditions
+      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+      PARTICULAR PURPOSE. You are solely responsible for determining the
+      appropriateness of using or redistributing the Work and assume any
+      risks associated with Your exercise of permissions under this License.
+
+   8. Limitation of Liability. In no event and under no legal theory,
+      whether in tort (including negligence), contract, or otherwise,
+      unless required by applicable law (such as deliberate and grossly
+      negligent acts) or agreed to in writing, shall any Contributor be
+      liable to You for damages, including any direct, indirect, special,
+      incidental, or consequential damages of any character arising as a
+      result of this License or out of the use or inability to use the
+      Work (including but not limited to damages for loss of goodwill,
+      work stoppage, computer failure or malfunction, or any and all
+      other commercial damages or losses), even if such Contributor
+      has been advised of the possibility of such damages.
+
+   9. Accepting Warranty or Additional Liability. While redistributing
+      the Work or Derivative Works thereof, You may choose to offer,
+      and charge a fee for, acceptance of support, warranty, indemnity,
+      or other liability obligations and/or rights consistent with this
+      License. However, in accepting such obligations, You may act only
+      on Your own behalf and on Your sole responsibility, not on behalf
+      of any other Contributor, and only if You agree to indemnify,
+      defend, and hold each Contributor harmless for any liability
+      incurred by, or claims asserted against, such Contributor by reason
+      of your accepting any such warranty or additional liability.
+
+   END OF TERMS AND CONDITIONS
+
+   APPENDIX: How to apply the Apache License to your work.
+
+      To apply the Apache License to your work, attach the following
+      boilerplate notice, with the fields enclosed by brackets "[]"
+      replaced with your own identifying information. (Don't include
+      the brackets!)  The text should be enclosed in the appropriate
+      comment syntax for the file format. We also recommend that a
+      file or class name and description of purpose be included on the
+      same "printed page" as the copyright notice for easier
+      identification within third-party archives.
+
+   Copyright [yyyy] [name of copyright owner]
+
+   Licensed 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.
+

Propchange: geronimo/sandbox/gshell/trunk/gshell-maven-plugin/LICENSE.txt
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/sandbox/gshell/trunk/gshell-maven-plugin/LICENSE.txt
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: geronimo/sandbox/gshell/trunk/gshell-maven-plugin/LICENSE.txt
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: geronimo/sandbox/gshell/trunk/gshell-maven-plugin/NOTICE.txt
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/gshell-maven-plugin/NOTICE.txt?rev=573330&view=auto
==============================================================================
--- geronimo/sandbox/gshell/trunk/gshell-maven-plugin/NOTICE.txt (added)
+++ geronimo/sandbox/gshell/trunk/gshell-maven-plugin/NOTICE.txt Thu Sep  6 11:20:42 2007
@@ -0,0 +1,5 @@
+Apache Geronimo
+Copyright 2006 The Apache Software Foundation
+
+This product includes software developed at
+The Apache Software Foundation (http://www.apache.org/).

Propchange: geronimo/sandbox/gshell/trunk/gshell-maven-plugin/NOTICE.txt
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/sandbox/gshell/trunk/gshell-maven-plugin/NOTICE.txt
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: geronimo/sandbox/gshell/trunk/gshell-maven-plugin/NOTICE.txt
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: geronimo/sandbox/gshell/trunk/gshell-maven-plugin/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/gshell-maven-plugin/pom.xml?rev=573330&view=auto
==============================================================================
--- geronimo/sandbox/gshell/trunk/gshell-maven-plugin/pom.xml (added)
+++ geronimo/sandbox/gshell/trunk/gshell-maven-plugin/pom.xml Thu Sep  6 11:20:42 2007
@@ -0,0 +1,96 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+    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.
+-->
+
+<!-- $Id$ -->
+
+<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>
+
+    <parent>
+        <groupId>org.apache.geronimo.gshell</groupId>
+        <artifactId>gshell</artifactId>
+        <version>1.0-alpha-1-SNAPSHOT</version>
+    </parent>
+
+    <artifactId>gshell-maven-plugin</artifactId>
+    <name>GShell Maven Plugin</name>
+    <packaging>maven-plugin</packaging>
+
+    <description>
+        Provides build integration wtih GShell.
+    </description>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.apache.geronimo.gshell</groupId>
+            <artifactId>gshell-plugin</artifactId>
+            <version>${pom.version}</version>
+        </dependency>
+        
+        <dependency>
+            <groupId>org.apache.maven</groupId>
+            <artifactId>maven-plugin-api</artifactId>
+            <version>2.0.5</version>
+        </dependency>
+        
+        <dependency>
+            <groupId>org.apache.maven</groupId>
+            <artifactId>maven-model</artifactId>
+            <version>2.0.5</version>
+        </dependency>
+        
+        <dependency>
+            <groupId>org.apache.maven</groupId>
+            <artifactId>maven-project</artifactId>
+            <version>2.0.5</version>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.xbean</groupId>
+            <artifactId>xbean-finder</artifactId>
+            <version>3.1</version>
+        </dependency>
+        
+        <dependency>
+            <groupId>org.codehaus.plexus</groupId>
+            <artifactId>plexus-cdc</artifactId>
+            <version>1.0-alpha-11-SNAPSHOT</version>
+        </dependency>
+        
+        <dependency>
+            <groupId>org.codehaus.plexus</groupId>
+            <artifactId>plexus-component-annotations</artifactId>
+        </dependency>
+        
+        <dependency>
+            <groupId>asm</groupId>
+            <artifactId>asm</artifactId>
+            <version>2.2.3</version>
+            <scope>runtime</scope>
+        </dependency>
+        
+        <dependency>
+            <groupId>asm</groupId>
+            <artifactId>asm-commons</artifactId>
+            <version>2.2.3</version>
+            <scope>runtime</scope>
+        </dependency>
+    </dependencies>
+
+</project>

Propchange: geronimo/sandbox/gshell/trunk/gshell-maven-plugin/pom.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/sandbox/gshell/trunk/gshell-maven-plugin/pom.xml
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: geronimo/sandbox/gshell/trunk/gshell-maven-plugin/pom.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: geronimo/sandbox/gshell/trunk/gshell-maven-plugin/src/main/java/org/apache/geronimo/gshell/maven/gshell/PluginDescriptorMojo.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/gshell-maven-plugin/src/main/java/org/apache/geronimo/gshell/maven/gshell/PluginDescriptorMojo.java?rev=573330&view=auto
==============================================================================
--- geronimo/sandbox/gshell/trunk/gshell-maven-plugin/src/main/java/org/apache/geronimo/gshell/maven/gshell/PluginDescriptorMojo.java (added)
+++ geronimo/sandbox/gshell/trunk/gshell-maven-plugin/src/main/java/org/apache/geronimo/gshell/maven/gshell/PluginDescriptorMojo.java Thu Sep  6 11:20:42 2007
@@ -0,0 +1,232 @@
+/*
+ * 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.gshell.maven.gshell;
+
+import java.io.File;
+import java.io.StringWriter;
+import java.io.IOException;
+import java.io.FileWriter;
+import java.io.BufferedWriter;
+import java.lang.reflect.Field;
+import java.net.MalformedURLException;
+import java.net.URL;
+import java.net.URLClassLoader;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Collections;
+
+import org.apache.geronimo.gshell.plugin.model.Command;
+import org.apache.geronimo.gshell.plugin.model.Plugin;
+import org.apache.geronimo.gshell.plugin.model.io.xpp3.PluginXpp3Writer;
+
+import org.apache.maven.plugin.AbstractMojo;
+import org.apache.maven.plugin.MojoExecutionException;
+import org.apache.maven.project.MavenProject;
+
+import org.apache.xbean.finder.ClassFinder;
+
+import org.codehaus.plexus.component.annotations.Component;
+import org.codehaus.plexus.component.annotations.Configuration;
+import org.codehaus.plexus.component.annotations.Parameter;
+import org.codehaus.plexus.component.annotations.Requirement;
+import org.codehaus.plexus.component.repository.cdc.ComponentDescriptor;
+import org.codehaus.plexus.component.repository.cdc.ComponentRequirement;
+import org.codehaus.plexus.configuration.xml.XmlPlexusConfiguration;
+import org.codehaus.plexus.util.DirectoryScanner;
+
+/**
+ * Generates a GShell XML plugin descriptor.
+ *
+ * @goal plugin-descriptor
+ * @phase process-classes
+ * @requiresDependencyResolution runtime
+ *
+ * @version $Rev$ $Date$
+ */
+public class PluginDescriptorMojo
+    extends AbstractMojo
+{
+    /**
+     * The directory where class files have been built.
+     *
+     * @parameter expression="${project.build.outputDirectory}
+     */
+    private File classesDirectory;
+
+    /**
+     * The full list of compile time dependencies.
+     *
+     * @parameter expression="${project.compileClasspathElements}
+     * @readonly
+     */
+    private List<String> classpathElements;
+
+    /**
+     * The location where the generated descriptor will be placed.
+     *
+     * @parameter expression="${project.build.outputDirectory}"
+     */
+    private File outputDirectory;
+
+    /**
+     * The filename of the descriptor.
+     *
+     * @parameter expression="META-INF/gshell/plugin.xml"
+     * @required
+     */
+    private String fileName;
+
+    /**
+     * @parameter expression="${project}"
+     * @readonly
+     * @required
+     */
+    private MavenProject project;
+
+    //
+    // Mojo
+    //
+
+    protected URL[] getClasspath() {
+        List<URL> list = new ArrayList<URL>();
+
+        // Add the projects dependencies
+        for (String filename : classpathElements) {
+            try {
+                list.add(new File(filename).toURI().toURL());
+            }
+            catch (MalformedURLException e) {
+                throw new RuntimeException(e);
+            }
+        }
+
+        /*
+        for (Object obj : list) {
+            System.err.println("    " + obj);
+        }
+        */
+
+        return (URL[])list.toArray(new URL[list.size()]);
+    }
+
+    public void execute() throws MojoExecutionException {
+        //
+        // FIXME: This is one huge hack after another...
+        //
+
+        DirectoryScanner scanner = new DirectoryScanner();
+        scanner.setBasedir(classesDirectory);
+        scanner.setIncludes(new String[]{"**/*.class"});
+        scanner.scan();
+
+        //
+        // FIXME: Probably better to use QDox instead of this crapo...
+        //
+
+        URL[] classpath = getClasspath();
+        ClassLoader parent = getClass().getClassLoader();
+        ClassLoader cl = new URLClassLoader(classpath, parent);
+        
+        List<Class> localClasses = new ArrayList<Class>();
+
+        for (String file : scanner.getIncludedFiles()) {
+            String className = file.substring( 0, file.lastIndexOf( ".class" ) ).replace( '\\', '.' ).replace( '/', '.' );
+            Class<?> c;
+
+            try {
+                c = cl.loadClass(className);
+            }
+            catch (ClassNotFoundException e) {
+                throw new MojoExecutionException("Error scanning class " + className, e);
+            }
+
+            localClasses.add(c);
+        }
+
+        List<Class> commands = new ClassFinder(localClasses).findAnnotatedClasses(org.apache.geronimo.gshell.command.annotation.Command.class);
+
+        Plugin plugin = new Plugin();
+        plugin.setName(project.getArtifactId());
+        
+        for (Class type : commands) {
+            org.apache.geronimo.gshell.command.annotation.Command meta = (org.apache.geronimo.gshell.command.annotation.Command)
+                    type.getAnnotation(org.apache.geronimo.gshell.command.annotation.Command.class);
+
+            Command c = new Command();
+
+            c.setName(meta.name());
+            c.setDescription(meta.description());
+            c.setComment(meta.comment());
+            c.setImplementation(type.getName());
+
+            // Have to look at each class in the tree to look at its declared fields
+            List<Class> classes = new ArrayList<Class>();
+            while (type != null) {
+                classes.add(type);
+                type = type.getSuperclass();
+            }
+            
+            for (Class t : classes) {
+                for (Field f : t.getDeclaredFields()) {
+                    Requirement requirement = f.getAnnotation(Requirement.class);
+
+                    if (requirement != null) {
+                        org.apache.geronimo.gshell.plugin.model.Requirement r = new org.apache.geronimo.gshell.plugin.model.Requirement();
+
+                        if (requirement.role().isAssignableFrom(Object.class)) {
+                            r.setRole(f.getType().getName());
+                        }
+                        else {
+                            r.setRole(requirement.role().getName());
+                        }
+
+                        r.setRoleHint(requirement.hint());
+                        r.setFieldName(f.getName());
+                        // req.setFieldMappingType(f.getType().getName());
+
+                        c.addRequirement(r);
+                    }
+                }
+            }
+
+            //
+            // TODO: Configuration?
+            //
+
+            plugin.addCommand(c);
+        }
+
+        File outputFile = new File(outputDirectory, fileName);
+        if (!outputFile.getParentFile().exists() && !outputFile.getParentFile().mkdirs()) {
+            throw new MojoExecutionException("Cannot create directory: " + outputFile.getParent());
+        }
+        
+        try {
+            BufferedWriter output = new BufferedWriter(new FileWriter(outputFile));
+            PluginXpp3Writer writer = new PluginXpp3Writer();
+            
+            writer.write(output, plugin);
+            output.close();
+        }
+        catch (IOException e) {
+            throw new MojoExecutionException("Failed to write plugin descriptor", e);
+        }
+    }
+}
\ No newline at end of file

Propchange: geronimo/sandbox/gshell/trunk/gshell-maven-plugin/src/main/java/org/apache/geronimo/gshell/maven/gshell/PluginDescriptorMojo.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/sandbox/gshell/trunk/gshell-maven-plugin/src/main/java/org/apache/geronimo/gshell/maven/gshell/PluginDescriptorMojo.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: geronimo/sandbox/gshell/trunk/gshell-maven-plugin/src/main/java/org/apache/geronimo/gshell/maven/gshell/PluginDescriptorMojo.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/CommandDescriptor.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/CommandDescriptor.java?rev=573330&view=auto
==============================================================================
--- geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/CommandDescriptor.java (added)
+++ geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/CommandDescriptor.java Thu Sep  6 11:20:42 2007
@@ -0,0 +1,74 @@
+/*
+ * 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.gshell.plugin;
+
+import org.codehaus.plexus.component.repository.ComponentDescriptor;
+import org.codehaus.plexus.configuration.PlexusConfiguration;
+
+/**
+ * Container for plugin descriptions.
+ *
+ * @version $Rev$ $Date$
+ */
+public class CommandDescriptor
+    extends ComponentDescriptor
+{
+    private String name;
+
+    private String description;
+
+    private String comment;
+
+    private Object configuration;
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(final String name) {
+        assert name != null;
+
+        this.name = name;
+    }
+
+    public String getDescription() {
+        return description;
+    }
+
+    public void setDescription(final String description) {
+        this.description = description;
+    }
+
+    public String getComment() {
+        return comment;
+    }
+
+    public void setComment(final String comment) {
+        this.comment = comment;
+    }
+
+    public void setCommandConfiguration(final PlexusConfiguration configuration) {
+        this.configuration = configuration;
+    }
+
+    public Object getCommandConfiguration() {
+        return configuration;
+    }
+}

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/CommandDescriptor.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/CommandDescriptor.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/CommandDescriptor.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Copied: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginCollector.java (from r572601, geronimo/sandbox/gshell/trunk/gshell-core/src/main/java/org/apache/geronimo/gshell/GShellPluginCollector.java)
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginCollector.java?p2=geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginCollector.java&p1=geronimo/sandbox/gshell/trunk/gshell-core/src/main/java/org/apache/geronimo/gshell/GShellPluginCollector.java&r1=572601&r2=573330&rev=573330&view=diff
==============================================================================
--- geronimo/sandbox/gshell/trunk/gshell-core/src/main/java/org/apache/geronimo/gshell/GShellPluginCollector.java (original)
+++ geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginCollector.java Thu Sep  6 11:20:42 2007
@@ -17,12 +17,13 @@
  * under the License.
  */
 
-package org.apache.geronimo.gshell;
+package org.apache.geronimo.gshell.plugin;
 
 import org.codehaus.plexus.component.annotations.Component;
 import org.codehaus.plexus.component.discovery.ComponentDiscoveryEvent;
 import org.codehaus.plexus.component.discovery.ComponentDiscoveryListener;
 import org.codehaus.plexus.component.repository.ComponentSetDescriptor;
+import org.codehaus.plexus.component.repository.ComponentDescriptor;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -31,8 +32,8 @@
  * 
  * @version $Rev$ $Date$
  */
-@Component(role=GShellPluginCollector.class)
-public class GShellPluginCollector
+@Component(role=ComponentDiscoveryListener.class, hint="gshell")
+public class PluginCollector
     implements ComponentDiscoveryListener
 {
     public static final String ID = "gshell-plugin-collector";
@@ -48,6 +49,14 @@
 
         ComponentSetDescriptor desc = event.getComponentSetDescriptor();
 
-        log.debug("Component(s) discovered: {}", desc);
+        for (Object obj : desc.getComponents()) {
+            ComponentDescriptor c = (ComponentDescriptor)obj;
+            
+            log.debug("Component discovered: {}", c.getHumanReadableKey());
+        }
+        
+        //
+        // TODO: Figure out wtf we want to do here...
+        //
     }
 }

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginCollector.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginCollector.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginCollector.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDescriptor.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDescriptor.java?rev=573330&view=auto
==============================================================================
--- geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDescriptor.java (added)
+++ geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDescriptor.java Thu Sep  6 11:20:42 2007
@@ -0,0 +1,107 @@
+/*
+ * 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.gshell.plugin;
+
+import java.util.List;
+
+import org.apache.geronimo.gshell.plugin.model.Command;
+import org.codehaus.plexus.component.composition.Requirement;
+import org.codehaus.plexus.component.repository.ComponentSetDescriptor;
+
+/**
+ * Container for additional component information for GShell plugins.
+ *
+ * @version $Rev$ $Date$
+ */
+public class PluginDescriptor
+    extends ComponentSetDescriptor
+{
+    private String name;
+
+    private String description;
+
+    private String comment;
+
+    private List<Command> commands;
+
+    private Object configuration;
+    
+    private List<Requirement> requirements;
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(final String name) {
+        assert name != null;
+        
+        this.name = name;
+    }
+
+    public String getDescription() {
+        return description;
+    }
+
+    public void setDescription(final String description) {
+        this.description = description;
+    }
+
+    public String getComment() {
+        return comment;
+    }
+
+    public void setComment(final String comment) {
+        this.comment = comment;
+    }
+
+    public List<Command> getCommands() {
+        return commands;
+    }
+
+    public void setCommands(final List<Command> commands) {
+        assert name != null;
+        
+        this.commands = commands;
+    }
+
+    public Object getConfiguration() {
+        return configuration;
+    }
+
+    public void setConfiguration(final Object configuration) {
+        this.configuration = configuration;
+    }
+
+    public List<Requirement> getRequirements() {
+        return requirements;
+    }
+
+    public void setRequirements(final List<Requirement> requirements) {
+        assert name != null;
+        
+        this.requirements = requirements;
+    }
+
+    public void addCommandDescriptor(final CommandDescriptor desc) {
+        assert desc != null;
+
+        addComponentDescriptor(desc);
+    }
+}
\ No newline at end of file

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDescriptor.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDescriptor.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDescriptor.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDescriptorBuilder.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDescriptorBuilder.java?rev=573330&view=auto
==============================================================================
--- geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDescriptorBuilder.java (added)
+++ geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDescriptorBuilder.java Thu Sep  6 11:20:42 2007
@@ -0,0 +1,102 @@
+/*
+ * 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.gshell.plugin;
+
+import java.io.Reader;
+
+import org.apache.geronimo.gshell.command.Command;
+import org.codehaus.plexus.component.repository.ComponentRequirement;
+import org.codehaus.plexus.component.repository.io.PlexusTools;
+import org.codehaus.plexus.configuration.PlexusConfiguration;
+import org.codehaus.plexus.configuration.PlexusConfigurationException;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Helper to build {@link PluginDescriptor} instances from configuration stream.
+ *
+ * @version $Rev$ $Date$
+ */
+public class PluginDescriptorBuilder
+{
+    private Logger log = LoggerFactory.getLogger(getClass());
+    
+    public PluginDescriptor build(final Reader reader, final String source) throws PlexusConfigurationException {
+        assert reader != null;
+        assert source != null;
+
+        PlexusConfiguration c = PlexusTools.buildConfiguration(source, reader);
+
+        PluginDescriptor pd = new PluginDescriptor();
+
+        pd.setName(c.getChild("name").getValue());
+        pd.setDescription(c.getChild("description").getValue());
+        pd.setComment(c.getChild("comment").getValue());
+
+        log.debug("Loading plugin: {}", pd.getName());
+
+        // Commands
+        PlexusConfiguration[] commands = c.getChild("commands").getChildren("command");
+
+        for (PlexusConfiguration command : commands) {
+            CommandDescriptor d = createCommandDescriptor(command);
+            pd.addCommandDescriptor(d);
+        }
+        
+        return pd;
+    }
+
+    private CommandDescriptor createCommandDescriptor(final PlexusConfiguration c) throws PlexusConfigurationException {
+        assert c != null;
+
+        CommandDescriptor d = new CommandDescriptor();
+
+        d.setName(c.getChild("name").getValue());
+        d.setDescription(c.getChild("description").getValue());
+        d.setComment(c.getChild("comment").getValue());
+        d.setImplementation(c.getChild("implementation").getValue());
+        d.setCommandConfiguration(c.getChild("configuration"));
+
+        log.debug("Loading command: {}", d.getName());
+
+        d.setRole(Command.class.getName());
+        d.setRoleHint(d.getName());
+
+        //
+        // HACK: For now just use this, make it configurable later, look at ComponentDescriptor and see what else we want to expose
+        //
+        d.setInstantiationStrategy("per-lookup");
+        
+        // Requirements
+        PlexusConfiguration[] requirements = c.getChild("requirements").getChildren("requirement");
+
+        for (PlexusConfiguration requirement : requirements) {
+            ComponentRequirement r = new ComponentRequirement();
+            
+            r.setRole(requirement.getChild("role").getValue());
+            r.setRoleHint(requirement.getChild("role-hint").getValue());
+            r.setFieldName(requirement.getChild("field-name").getValue());
+
+            d.addRequirement(r);
+        }
+
+        return d;
+    }
+}
\ No newline at end of file

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDescriptorBuilder.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDescriptorBuilder.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDescriptorBuilder.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Copied: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDiscoverer.java (from r572601, geronimo/sandbox/gshell/trunk/gshell-core/src/main/java/org/apache/geronimo/gshell/GShellPluginDiscoverer.java)
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDiscoverer.java?p2=geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDiscoverer.java&p1=geronimo/sandbox/gshell/trunk/gshell-core/src/main/java/org/apache/geronimo/gshell/GShellPluginDiscoverer.java&r1=572601&r2=573330&rev=573330&view=diff
==============================================================================
--- geronimo/sandbox/gshell/trunk/gshell-core/src/main/java/org/apache/geronimo/gshell/GShellPluginDiscoverer.java (original)
+++ geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDiscoverer.java Thu Sep  6 11:20:42 2007
@@ -17,25 +17,42 @@
  * under the License.
  */
 
-package org.apache.geronimo.gshell;
+package org.apache.geronimo.gshell.plugin;
+
+import java.io.Reader;
 
 import org.codehaus.plexus.component.annotations.Component;
-import org.codehaus.plexus.component.discovery.DefaultComponentDiscoverer;
+import org.codehaus.plexus.component.discovery.AbstractComponentDiscoverer;
+import org.codehaus.plexus.component.discovery.ComponentDiscoverer;
+import org.codehaus.plexus.component.repository.ComponentSetDescriptor;
+import org.codehaus.plexus.configuration.PlexusConfigurationException;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
 /**
- * Custom Plexus component discovery compoentn to handle the GShell plugin.xml muck.
+ * Custom Plexus component discovery component to handle the GShell plugin.xml muck.
  *
  * @version $Rev$ $Date$
  */
-@Component(role=GShellPluginDiscoverer.class)
-public class GShellPluginDiscoverer
-    extends DefaultComponentDiscoverer// AbstractComponentDiscoverer
+@Component(role= ComponentDiscoverer.class, hint="gshell")
+public class PluginDiscoverer
+    extends AbstractComponentDiscoverer
 {
+    public static final String PLUGIN_XML_LOCATION = "META-INF/gshell/plugin.xml";
+
     private final Logger log = LoggerFactory.getLogger(getClass());
+    
+    private final PluginDescriptorBuilder builder = new PluginDescriptorBuilder();
+
+    public String getComponentDescriptorLocation() {
+        return PLUGIN_XML_LOCATION;
+    }
 
-    //
-    // TODO: Put the custom plugin.xml descriptor muck here...
-    //
+    public ComponentSetDescriptor createComponentDescriptors(final Reader reader, final String source)
+        throws PlexusConfigurationException
+    {
+        log.debug("Creating components from: {}", source);
+        
+        return builder.build(reader, source);
+    }
 }

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDiscoverer.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDiscoverer.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/PluginDiscoverer.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/model/package-info.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/model/package-info.java?rev=573330&view=auto
==============================================================================
--- geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/model/package-info.java (added)
+++ geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/model/package-info.java Thu Sep  6 11:20:42 2007
@@ -0,0 +1,25 @@
+/*
+ * 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.
+ */
+
+/**
+ * Provides the model for the plugin configuration.
+ *
+ * @version $Rev$ $Date$
+ */
+package org.apache.geronimo.gshell.plugin.model;
\ No newline at end of file

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/model/package-info.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/model/package-info.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/model/package-info.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/package-info.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/package-info.java?rev=573330&view=auto
==============================================================================
--- geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/package-info.java (added)
+++ geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/package-info.java Thu Sep  6 11:20:42 2007
@@ -0,0 +1,25 @@
+/*
+ * 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.
+ */
+
+/**
+ * Plugin support.
+ *
+ * @version $Rev$ $Date$
+ */
+package org.apache.geronimo.gshell.plugin;
\ No newline at end of file

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/package-info.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/package-info.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/java/org/apache/geronimo/gshell/plugin/package-info.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Modified: geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/mdo/plugin.mdo
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/mdo/plugin.mdo?rev=573330&r1=573329&r2=573330&view=diff
==============================================================================
--- geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/mdo/plugin.mdo (original)
+++ geronimo/sandbox/gshell/trunk/gshell-plugin/src/main/mdo/plugin.mdo Thu Sep  6 11:20:42 2007
@@ -36,6 +36,10 @@
         </default>
     </defaults>
 
+    <!--
+    TODO: Add configuration for the command manager/container to handle init and other shiz...
+    -->
+
     <classes>
         <class java.abstract="true">
             <name>Element</name>
@@ -71,6 +75,10 @@
             </fields>
         </class>
 
+        <!--
+        FIXME: Use some kinda suffix on these class names, like *Model, or *Element er something so these names don't clash with our other classes of the same name.
+        -->
+
         <class rootElement="true" xml.tagName="plugin">
             <name>Plugin</name>
             <superClass>Element</superClass>
@@ -142,14 +150,14 @@
                     <required>true</required>
                 </field>
 
-                <field>
-                    <name>hint</name>
+                <field xml.tagName="role-hint">
+                    <name>roleHint</name>
                     <version>1.0.0+</version>
                     <type>String</type>
                 </field>
 
-                <field>
-                    <name>field</name>
+                <field xml.tagName="field-name">
+                    <name>fieldName</name>
                     <version>1.0.0+</version>
                     <type>String</type>
                     <required>true</required>

Modified: geronimo/sandbox/gshell/trunk/gshell-plugin/src/test/java/org/apache/geronimo/gshell/plugin/model/BasicModelValidationTest.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/gshell-plugin/src/test/java/org/apache/geronimo/gshell/plugin/model/BasicModelValidationTest.java?rev=573330&r1=573329&r2=573330&view=diff
==============================================================================
--- geronimo/sandbox/gshell/trunk/gshell-plugin/src/test/java/org/apache/geronimo/gshell/plugin/model/BasicModelValidationTest.java (original)
+++ geronimo/sandbox/gshell/trunk/gshell-plugin/src/test/java/org/apache/geronimo/gshell/plugin/model/BasicModelValidationTest.java Thu Sep  6 11:20:42 2007
@@ -57,7 +57,7 @@
         Requirement req = (Requirement) command.getRequirements().get(0);
         assertNotNull(req);
         assertEquals("org.codehaus.plexus.PlexusContainer", req.getRole());
-        assertEquals("container", req.getField());
+        assertEquals("container", req.getFieldName());
 
         assertNotNull(command.getConfiguration());
 

Modified: geronimo/sandbox/gshell/trunk/gshell-plugin/src/test/resources/org/apache/geronimo/gshell/plugin/model/plugins1.xml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/gshell-plugin/src/test/resources/org/apache/geronimo/gshell/plugin/model/plugins1.xml?rev=573330&r1=573329&r2=573330&view=diff
==============================================================================
--- geronimo/sandbox/gshell/trunk/gshell-plugin/src/test/resources/org/apache/geronimo/gshell/plugin/model/plugins1.xml (original)
+++ geronimo/sandbox/gshell/trunk/gshell-plugin/src/test/resources/org/apache/geronimo/gshell/plugin/model/plugins1.xml Thu Sep  6 11:20:42 2007
@@ -27,15 +27,18 @@
         <command>
             <name>builtins.HelpCommand</name>
             <implementation>org.apache.geronimo.gshell.commands.builtins.HelpCommand</implementation>
+
             <requirements>
                 <requirement>
                     <role>org.codehaus.plexus.PlexusContainer</role>
-                    <field>container</field>
+                    <field-name>container</field-name>
                 </requirement>
             </requirements>
+
             <configuration>
                 <foo>bar</foo>
             </configuration>
         </command>
     </commands>
+
 </plugin>

Modified: geronimo/sandbox/gshell/trunk/javacc-maven-plugin/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/javacc-maven-plugin/pom.xml?rev=573330&r1=573329&r2=573330&view=diff
==============================================================================
--- geronimo/sandbox/gshell/trunk/javacc-maven-plugin/pom.xml (original)
+++ geronimo/sandbox/gshell/trunk/javacc-maven-plugin/pom.xml Thu Sep  6 11:20:42 2007
@@ -81,33 +81,6 @@
     </dependencies>
 
     <build>
-        <defaultGoal>install</defaultGoal>
-        
-        <pluginManagement>
-            <plugins>
-                <plugin>
-                    <groupId>org.apache.maven.plugins</groupId>
-                    <artifactId>maven-release-plugin</artifactId>
-                    <version>2.0-beta-4</version>
-                </plugin>
-
-                <plugin>
-                    <groupId>org.apache.maven.plugins</groupId>
-                    <artifactId>maven-surefire-plugin</artifactId>
-                    <version>2.3</version>
-                    <configuration>
-                        <redirectTestOutputToFile>true</redirectTestOutputToFile>
-                    </configuration>
-                </plugin>
-
-                <plugin>
-                    <groupId>org.apache.maven.plugins</groupId>
-                    <artifactId>maven-install-plugin</artifactId>
-                    <version>2.2</version>
-                </plugin>
-            </plugins>
-        </pluginManagement>
-        
         <plugins>
             <plugin>
                 <groupId>org.apache.maven.plugins</groupId>

Modified: geronimo/sandbox/gshell/trunk/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gshell/trunk/pom.xml?rev=573330&r1=573329&r2=573330&view=diff
==============================================================================
--- geronimo/sandbox/gshell/trunk/pom.xml (original)
+++ geronimo/sandbox/gshell/trunk/pom.xml Thu Sep  6 11:20:42 2007
@@ -346,6 +346,7 @@
         <module>gshell-plugin</module>
         <module>gshell-core</module>
         <module>gshell-cli</module>
+        <module>gshell-maven-plugin</module>
         <module>gshell-commands</module>
         <module>gshell-testsuite</module>
         <module>gshell-assembly</module>



Mime
View raw message