geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jdil...@apache.org
Subject svn commit: r439997 - in /geronimo/genesis/trunk/plugins: plugin-support/ plugin-support/src/main/java/org/apache/geronimo/genesis/ plugin-support/src/main/java/org/apache/geronimo/plugin/ plugin-support/src/main/resources/ script-maven-plugin/src/main...
Date Mon, 04 Sep 2006 09:44:52 GMT
Author: jdillon
Date: Mon Sep  4 02:44:50 2006
New Revision: 439997

URL: http://svn.apache.org/viewvc?view=rev&rev=439997
Log:
Move all classes under o.a.g.genesis
Adding JCL Log adapter so all mojo's can use it

Added:
    geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/ArtifactItem.java
  (contents, props changed)
      - copied, changed from r438225, geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/plugin/ArtifactItem.java
    geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/MavenPluginLog.java
      - copied, changed from r439901, geronimo/server/trunk/maven-plugins/geronimo-maven-plugin/src/main/java/org/apache/geronimo/mavenplugins/geronimo/MavenPluginLog.java
    geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/MojoSupport.java
  (contents, props changed)
      - copied, changed from r439749, geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/plugin/MojoSupport.java
    geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/ObjectHolder.java
      - copied, changed from r439898, geronimo/server/trunk/maven-plugins/geronimo-maven-plugin/src/main/java/org/apache/geronimo/mavenplugins/geronimo/ObjectHolder.java
    geronimo/genesis/trunk/plugins/plugin-support/src/main/resources/commons-logging.properties
      - copied, changed from r439899, geronimo/server/trunk/maven-plugins/geronimo-maven-plugin/src/main/resources/commons-logging.properties
Removed:
    geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/plugin/
Modified:
    geronimo/genesis/trunk/plugins/plugin-support/pom.xml
    geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/AntLoggerAdapter.java
    geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/AntMojoSupport.java
    geronimo/genesis/trunk/plugins/script-maven-plugin/src/main/java/org/apache/geronimo/genesis/plugins/script/GroovyMojo.java
    geronimo/genesis/trunk/plugins/tools-maven-plugin/src/main/java/org/apache/geronimo/genesis/plugins/tools/GpgSignAttachedMojo.java
    geronimo/genesis/trunk/plugins/tools-maven-plugin/src/main/java/org/apache/geronimo/genesis/plugins/tools/RequireJavaVersionMojo.java

Modified: geronimo/genesis/trunk/plugins/plugin-support/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/genesis/trunk/plugins/plugin-support/pom.xml?view=diff&rev=439997&r1=439996&r2=439997
==============================================================================
--- geronimo/genesis/trunk/plugins/plugin-support/pom.xml (original)
+++ geronimo/genesis/trunk/plugins/plugin-support/pom.xml Mon Sep  4 02:44:50 2006
@@ -53,6 +53,12 @@
             <version>2.1</version>
         </dependency>
 
+        <dependency>
+            <groupId>commons-logging</groupId>
+            <artifactId>commons-logging</artifactId>
+            <version>1.0.4</version>
+        </dependency>
+
     </dependencies>
 
 </project>

Modified: geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/AntLoggerAdapter.java
URL: http://svn.apache.org/viewvc/geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/AntLoggerAdapter.java?view=diff&rev=439997&r1=439996&r2=439997
==============================================================================
--- geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/AntLoggerAdapter.java
(original)
+++ geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/AntLoggerAdapter.java
Mon Sep  4 02:44:50 2006
@@ -22,7 +22,6 @@
 import java.io.PrintStream;
 
 import org.apache.tools.ant.Project;
-import org.apache.tools.ant.BuildLogger;
 import org.apache.tools.ant.DefaultLogger;
 
 import org.apache.maven.plugin.logging.Log;

Modified: geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/AntMojoSupport.java
URL: http://svn.apache.org/viewvc/geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/AntMojoSupport.java?view=diff&rev=439997&r1=439996&r2=439997
==============================================================================
--- geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/AntMojoSupport.java
(original)
+++ geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/AntMojoSupport.java
Mon Sep  4 02:44:50 2006
@@ -20,7 +20,6 @@
 package org.apache.geronimo.genesis;
 
 import java.io.File;
-import java.io.PrintStream;
 
 import java.util.Map;
 import java.util.Iterator;
@@ -31,13 +30,9 @@
 import org.apache.tools.ant.Project;
 import org.apache.tools.ant.Task;
 import org.apache.tools.ant.BuildException;
-import org.apache.tools.ant.BuildLogger;
-import org.apache.tools.ant.DefaultLogger;
 import org.apache.tools.ant.types.FileSet;
 import org.apache.tools.ant.taskdefs.Mkdir;
 import org.apache.tools.ant.taskdefs.Property;
-
-import org.apache.geronimo.plugin.MojoSupport;
 
 /**
  * Support for Ant-based Mojos.

Copied: geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/ArtifactItem.java
(from r438225, geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/plugin/ArtifactItem.java)
URL: http://svn.apache.org/viewvc/geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/ArtifactItem.java?view=diff&rev=439997&p1=geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/plugin/ArtifactItem.java&r1=438225&p2=geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/ArtifactItem.java&r2=439997
==============================================================================
--- geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/plugin/ArtifactItem.java
(original)
+++ geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/ArtifactItem.java
Mon Sep  4 02:44:50 2006
@@ -17,7 +17,7 @@
  * under the License.
  */
 
-package org.apache.geronimo.plugin;
+package org.apache.geronimo.genesis;
 
 /**
  * Represents a Maven-artifact.

Propchange: geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/ArtifactItem.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/ArtifactItem.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/ArtifactItem.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Copied: geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/MavenPluginLog.java
(from r439901, geronimo/server/trunk/maven-plugins/geronimo-maven-plugin/src/main/java/org/apache/geronimo/mavenplugins/geronimo/MavenPluginLog.java)
URL: http://svn.apache.org/viewvc/geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/MavenPluginLog.java?view=diff&rev=439997&p1=geronimo/server/trunk/maven-plugins/geronimo-maven-plugin/src/main/java/org/apache/geronimo/mavenplugins/geronimo/MavenPluginLog.java&r1=439901&p2=geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/MavenPluginLog.java&r2=439997
==============================================================================
--- geronimo/server/trunk/maven-plugins/geronimo-maven-plugin/src/main/java/org/apache/geronimo/mavenplugins/geronimo/MavenPluginLog.java
(original)
+++ geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/MavenPluginLog.java
Mon Sep  4 02:44:50 2006
@@ -1,31 +1,30 @@
 /*
- *  Copyright 2006 The Apache Software Foundation
+ * 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
  *
- *  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
  *
- *     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.
+ * 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.mavenplugins.geronimo;
+package org.apache.geronimo.genesis;
 
 import org.apache.commons.logging.Log;
 
 import java.io.Serializable;
 
-//
-// TODO: Move this to MojoSupport
-//
-
 /**
- * ???
+ * Bridge from the Maven plugin Log to a JCL Log.
  *
  * @version $Rev$ $Date$
  */

Copied: geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/MojoSupport.java
(from r439749, geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/plugin/MojoSupport.java)
URL: http://svn.apache.org/viewvc/geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/MojoSupport.java?view=diff&rev=439997&p1=geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/plugin/MojoSupport.java&r1=439749&p2=geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/MojoSupport.java&r2=439997
==============================================================================
--- geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/plugin/MojoSupport.java
(original)
+++ geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/MojoSupport.java
Mon Sep  4 02:44:50 2006
@@ -17,7 +17,7 @@
  * under the License.
  */
 
-package org.apache.geronimo.plugin;
+package org.apache.geronimo.genesis;
 
 import java.util.List;
 
@@ -26,12 +26,14 @@
 import org.apache.maven.plugin.MojoFailureException;
 import org.apache.maven.plugin.logging.Log;
 import org.apache.maven.project.MavenProject;
+
 import org.apache.maven.artifact.Artifact;
 import org.apache.maven.artifact.repository.ArtifactRepository;
 import org.apache.maven.artifact.factory.ArtifactFactory;
 import org.apache.maven.artifact.resolver.ArtifactNotFoundException;
 import org.apache.maven.artifact.resolver.ArtifactResolutionException;
 import org.apache.maven.artifact.resolver.ArtifactResolver;
+
 import org.apache.maven.model.Dependency;
 
 /**
@@ -42,6 +44,18 @@
 public abstract class MojoSupport
     extends AbstractMojo
 {
+    static {
+        //
+        // NOTE: Force install our custom JCL Log bridge, and disable Geronimo's bootstrap
logging
+        //       in case any sub-clas ends up dependening on geronimo-kernel which will muck
+        //       with logging in unexpected ways.
+        //
+
+        System.setProperty("org.apache.commons.logging.LogFactory", "org.apache.commons.logging.impl.LogFactoryImpl");
+        System.setProperty("org.apache.commons.logging.Log", "org.apache.geronimo.genesis.MavenPluginLog");
+        System.setProperty("geronimo.bootstrap.logging.enabled", "false");
+    }
+
     /**
      * Instance logger.  This is initialized to the value of {@link #getLog}
      * on execution.
@@ -52,7 +66,10 @@
      * Initializes logging.  Called by {@link #execute}.
      */
     protected void init() throws MojoExecutionException, MojoFailureException {
-        log = getLog();
+        this.log = getLog();
+
+        // Install the bridge from JCL to this plugins Log
+        MavenPluginLog.setLog(log);
     }
 
     /**

Propchange: geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/MojoSupport.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/MojoSupport.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/MojoSupport.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Copied: geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/ObjectHolder.java
(from r439898, geronimo/server/trunk/maven-plugins/geronimo-maven-plugin/src/main/java/org/apache/geronimo/mavenplugins/geronimo/ObjectHolder.java)
URL: http://svn.apache.org/viewvc/geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/ObjectHolder.java?view=diff&rev=439997&p1=geronimo/server/trunk/maven-plugins/geronimo-maven-plugin/src/main/java/org/apache/geronimo/mavenplugins/geronimo/ObjectHolder.java&r1=439898&p2=geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/ObjectHolder.java&r2=439997
==============================================================================
--- geronimo/server/trunk/maven-plugins/geronimo-maven-plugin/src/main/java/org/apache/geronimo/mavenplugins/geronimo/ObjectHolder.java
(original)
+++ geronimo/genesis/trunk/plugins/plugin-support/src/main/java/org/apache/geronimo/genesis/ObjectHolder.java
Mon Sep  4 02:44:50 2006
@@ -1,20 +1,23 @@
 /*
- *  Copyright 2006 The Apache Software Foundation
+ * 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
  *
- *  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
  *
- *     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.
+ * 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.mavenplugins.geronimo;
+package org.apache.geronimo.genesis;
 
 /**
  * Simple helper that holds an object.

Copied: geronimo/genesis/trunk/plugins/plugin-support/src/main/resources/commons-logging.properties
(from r439899, geronimo/server/trunk/maven-plugins/geronimo-maven-plugin/src/main/resources/commons-logging.properties)
URL: http://svn.apache.org/viewvc/geronimo/genesis/trunk/plugins/plugin-support/src/main/resources/commons-logging.properties?view=diff&rev=439997&p1=geronimo/server/trunk/maven-plugins/geronimo-maven-plugin/src/main/resources/commons-logging.properties&r1=439899&p2=geronimo/genesis/trunk/plugins/plugin-support/src/main/resources/commons-logging.properties&r2=439997
==============================================================================
--- geronimo/server/trunk/maven-plugins/geronimo-maven-plugin/src/main/resources/commons-logging.properties
(original)
+++ geronimo/genesis/trunk/plugins/plugin-support/src/main/resources/commons-logging.properties
Mon Sep  4 02:44:50 2006
@@ -2,4 +2,4 @@
 ## $Rev$ $Date$
 ##
 
-org.apache.commons.logging.Log=org.apache.geronimo.mavenplugins.geronimo.MavenPluginLog
\ No newline at end of file
+org.apache.commons.logging.Log=org.apache.geronimo.genesis.MavenPluginLog
\ No newline at end of file

Modified: geronimo/genesis/trunk/plugins/script-maven-plugin/src/main/java/org/apache/geronimo/genesis/plugins/script/GroovyMojo.java
URL: http://svn.apache.org/viewvc/geronimo/genesis/trunk/plugins/script-maven-plugin/src/main/java/org/apache/geronimo/genesis/plugins/script/GroovyMojo.java?view=diff&rev=439997&r1=439996&r2=439997
==============================================================================
--- geronimo/genesis/trunk/plugins/script-maven-plugin/src/main/java/org/apache/geronimo/genesis/plugins/script/GroovyMojo.java
(original)
+++ geronimo/genesis/trunk/plugins/script-maven-plugin/src/main/java/org/apache/geronimo/genesis/plugins/script/GroovyMojo.java
Mon Sep  4 02:44:50 2006
@@ -19,8 +19,8 @@
 
 package org.apache.geronimo.genesis.plugins.script;
 
-import org.apache.geronimo.plugin.MojoSupport;
-import org.apache.geronimo.plugin.ArtifactItem;
+import org.apache.geronimo.genesis.MojoSupport;
+import org.apache.geronimo.genesis.ArtifactItem;
 
 import java.io.File;
 import java.io.InputStream;

Modified: geronimo/genesis/trunk/plugins/tools-maven-plugin/src/main/java/org/apache/geronimo/genesis/plugins/tools/GpgSignAttachedMojo.java
URL: http://svn.apache.org/viewvc/geronimo/genesis/trunk/plugins/tools-maven-plugin/src/main/java/org/apache/geronimo/genesis/plugins/tools/GpgSignAttachedMojo.java?view=diff&rev=439997&r1=439996&r2=439997
==============================================================================
--- geronimo/genesis/trunk/plugins/tools-maven-plugin/src/main/java/org/apache/geronimo/genesis/plugins/tools/GpgSignAttachedMojo.java
(original)
+++ geronimo/genesis/trunk/plugins/tools-maven-plugin/src/main/java/org/apache/geronimo/genesis/plugins/tools/GpgSignAttachedMojo.java
Mon Sep  4 02:44:50 2006
@@ -32,7 +32,7 @@
 import org.apache.maven.artifact.Artifact;
 import org.apache.maven.plugin.MojoExecutionException;
 import org.apache.commons.lang.SystemUtils;
-import org.apache.geronimo.plugin.MojoSupport;
+import org.apache.geronimo.genesis.MojoSupport;
 
 import org.codehaus.plexus.util.cli.Commandline;
 import org.codehaus.plexus.util.cli.CommandLineUtils;

Modified: geronimo/genesis/trunk/plugins/tools-maven-plugin/src/main/java/org/apache/geronimo/genesis/plugins/tools/RequireJavaVersionMojo.java
URL: http://svn.apache.org/viewvc/geronimo/genesis/trunk/plugins/tools-maven-plugin/src/main/java/org/apache/geronimo/genesis/plugins/tools/RequireJavaVersionMojo.java?view=diff&rev=439997&r1=439996&r2=439997
==============================================================================
--- geronimo/genesis/trunk/plugins/tools-maven-plugin/src/main/java/org/apache/geronimo/genesis/plugins/tools/RequireJavaVersionMojo.java
(original)
+++ geronimo/genesis/trunk/plugins/tools-maven-plugin/src/main/java/org/apache/geronimo/genesis/plugins/tools/RequireJavaVersionMojo.java
Mon Sep  4 02:44:50 2006
@@ -19,7 +19,7 @@
 
 package org.apache.geronimo.genesis.plugins.tools;
 
-import org.apache.geronimo.plugin.MojoSupport;
+import org.apache.geronimo.genesis.MojoSupport;
 
 import org.apache.commons.lang.SystemUtils;
 
@@ -34,8 +34,7 @@
  * @version $Rev$ $Date$
  */
 public class RequireJavaVersionMojo
-    extends MojoSupport
-{
+    extends MojoSupport {
     /**
      * Specify the required version of Java (1.1, 1.2, 1.3, 1.4, 1.5).
      *



Mime
View raw message