You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by di...@apache.org on 2004/01/03 07:45:40 UTC
cvs commit: maven/src/java/org/apache/maven/plugin JellyPlugin.java
dion 2004/01/02 22:45:40
Modified: src/java/org/apache/maven/jelly/tags/maven Tag:
MAVEN-1_0-BRANCH ParamCheck.java UserCheck.java
CopyResources.java PluginVarTag.java
src/java/org/apache/maven/util Tag: MAVEN-1_0-BRANCH
DVSLFormatter.java
src/test/java/org/apache/maven Tag: MAVEN-1_0-BRANCH
JAXPTest.java
src/test/java/org/apache/maven/plugin Tag: MAVEN-1_0-BRANCH
PluginManagerTest.java
src/java/org/apache/maven/cli Tag: MAVEN-1_0-BRANCH App.java
src/java/org/apache/maven/project Tag: MAVEN-1_0-BRANCH
Project.java
src/java/org/apache/maven Tag: MAVEN-1_0-BRANCH
MavenException.java
src/java/org/apache/maven/plugin Tag: MAVEN-1_0-BRANCH
JellyPlugin.java
Log:
Remove my @authors
Revision Changes Path
No revision
No revision
1.2.4.1 +1 -1 maven/src/java/org/apache/maven/jelly/tags/maven/ParamCheck.java
Index: ParamCheck.java
===================================================================
RCS file: /home/cvs/maven/src/java/org/apache/maven/jelly/tags/maven/ParamCheck.java,v
retrieving revision 1.2
retrieving revision 1.2.4.1
diff -u -r1.2 -r1.2.4.1
--- ParamCheck.java 14 Oct 2003 15:10:08 -0000 1.2
+++ ParamCheck.java 3 Jan 2004 06:45:39 -0000 1.2.4.1
@@ -61,7 +61,7 @@
import org.apache.maven.jelly.tags.BaseTagSupport;
/**
- * @author dion
+ * A tag to check parameters are being passed correctly
*/
public class ParamCheck extends BaseTagSupport
{
1.1.10.1 +1 -1 maven/src/java/org/apache/maven/jelly/tags/maven/UserCheck.java
Index: UserCheck.java
===================================================================
RCS file: /home/cvs/maven/src/java/org/apache/maven/jelly/tags/maven/UserCheck.java,v
retrieving revision 1.1
retrieving revision 1.1.10.1
diff -u -r1.1 -r1.1.10.1
--- UserCheck.java 31 Jul 2003 04:29:00 -0000 1.1
+++ UserCheck.java 3 Jan 2004 06:45:39 -0000 1.1.10.1
@@ -62,7 +62,7 @@
import org.apache.maven.jelly.tags.BaseTagSupport;
/**
- * @author dion
+ * A tag to check if a user name is set.
*/
public class UserCheck extends BaseTagSupport
{
1.2.4.1 +1 -2 maven/src/java/org/apache/maven/jelly/tags/maven/CopyResources.java
Index: CopyResources.java
===================================================================
RCS file: /home/cvs/maven/src/java/org/apache/maven/jelly/tags/maven/CopyResources.java,v
retrieving revision 1.2
retrieving revision 1.2.4.1
diff -u -r1.2 -r1.2.4.1
--- CopyResources.java 19 Aug 2003 04:25:39 -0000 1.2
+++ CopyResources.java 3 Jan 2004 06:45:39 -0000 1.2.4.1
@@ -73,7 +73,6 @@
/**
* A tag to copy resources to a given directory
*
- * @author dion
* @version $Revision$
*/
public class CopyResources extends BaseTagSupport
1.1.4.2 +1 -1 maven/src/java/org/apache/maven/jelly/tags/maven/PluginVarTag.java
Index: PluginVarTag.java
===================================================================
RCS file: /home/cvs/maven/src/java/org/apache/maven/jelly/tags/maven/PluginVarTag.java,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -r1.1.4.1 -r1.1.4.2
--- PluginVarTag.java 10 Dec 2003 23:08:44 -0000 1.1.4.1
+++ PluginVarTag.java 3 Jan 2004 06:45:39 -0000 1.1.4.2
@@ -66,7 +66,7 @@
import org.apache.maven.project.Project;
/**
- * @author dion
+ * A tag to retrieve values from plugins
*/
public class PluginVarTag extends BaseTagSupport
{
No revision
No revision
1.2.4.1 +1 -2 maven/src/java/org/apache/maven/util/DVSLFormatter.java
Index: DVSLFormatter.java
===================================================================
RCS file: /home/cvs/maven/src/java/org/apache/maven/util/DVSLFormatter.java,v
retrieving revision 1.2
retrieving revision 1.2.4.1
diff -u -r1.2 -r1.2.4.1
--- DVSLFormatter.java 19 Aug 2003 04:31:38 -0000 1.2
+++ DVSLFormatter.java 3 Jan 2004 06:45:39 -0000 1.2.4.1
@@ -67,7 +67,6 @@
* shouldn't be done in a DVSL stylesheet.
*
* @author <a href="mailto:pete-apache-dev@kazmier.com">Pete Kazmier</a>
- * @author <a href="mailto:dion@apache.org">dIon Gillard</a>
* @version $Id$
* @todo move to org.apache.maven.util or make a jelly tag
*/
No revision
No revision
1.4.10.1 +0 -2 maven/src/test/java/org/apache/maven/JAXPTest.java
Index: JAXPTest.java
===================================================================
RCS file: /home/cvs/maven/src/test/java/org/apache/maven/JAXPTest.java,v
retrieving revision 1.4
retrieving revision 1.4.10.1
diff -u -r1.4 -r1.4.10.1
--- JAXPTest.java 13 Apr 2003 00:56:02 -0000 1.4
+++ JAXPTest.java 3 Jan 2004 06:45:39 -0000 1.4.10.1
@@ -64,8 +64,6 @@
import org.xml.sax.helpers.XMLReaderFactory;
/**
- * @author dion
- *
* Tests to check JAXP is correctly configured and classes are being loaded
*/
public class JAXPTest extends TestCase
No revision
No revision
1.11.4.3 +0 -1 maven/src/test/java/org/apache/maven/plugin/PluginManagerTest.java
Index: PluginManagerTest.java
===================================================================
RCS file: /home/cvs/maven/src/test/java/org/apache/maven/plugin/PluginManagerTest.java,v
retrieving revision 1.11.4.2
retrieving revision 1.11.4.3
diff -u -r1.11.4.2 -r1.11.4.3
--- PluginManagerTest.java 2 Dec 2003 03:58:35 -0000 1.11.4.2
+++ PluginManagerTest.java 3 Jan 2004 06:45:39 -0000 1.11.4.3
@@ -69,7 +69,6 @@
import com.werken.forehead.Forehead;
/**
- * @author dion
* @author Brett Porter <a href="mailto:brett@apache.org">brett@apache.org</a>
*
*/
No revision
No revision
1.37.4.5 +1 -2 maven/src/java/org/apache/maven/cli/App.java
Index: App.java
===================================================================
RCS file: /home/cvs/maven/src/java/org/apache/maven/cli/App.java,v
retrieving revision 1.37.4.4
retrieving revision 1.37.4.5
diff -u -r1.37.4.4 -r1.37.4.5
--- App.java 31 Dec 2003 01:14:13 -0000 1.37.4.4
+++ App.java 3 Jan 2004 06:45:39 -0000 1.37.4.5
@@ -94,7 +94,6 @@
* encapsulated in the MavenSession bean.
*
* @author <a href="mailto:jason@zenplex.com">Jason van Zyl</a>
- * @author dIon Gillard
*
* @version $Id$
*
No revision
No revision
1.91.4.6 +1 -2 maven/src/java/org/apache/maven/project/Project.java
Index: Project.java
===================================================================
RCS file: /home/cvs/maven/src/java/org/apache/maven/project/Project.java,v
retrieving revision 1.91.4.5
retrieving revision 1.91.4.6
diff -u -r1.91.4.5 -r1.91.4.6
--- Project.java 3 Jan 2004 04:09:31 -0000 1.91.4.5
+++ Project.java 3 Jan 2004 06:45:39 -0000 1.91.4.6
@@ -91,7 +91,6 @@
/**
* @author <a href="mailto:jason@zenplex.com">Jason van Zyl</a>
* @author <a href="mailto:vmassol@apache.org">Vincent Massol</a>
- * @author <a href="mailto:dion@apache.org">dIon Gillard</a>
* @author <a href="mailto:glennm@apache.org">Glenn McAllister</a>
*
* @version $Id$
No revision
No revision
1.4.10.1 +1 -2 maven/src/java/org/apache/maven/MavenException.java
Index: MavenException.java
===================================================================
RCS file: /home/cvs/maven/src/java/org/apache/maven/MavenException.java,v
retrieving revision 1.4
retrieving revision 1.4.10.1
diff -u -r1.4 -r1.4.10.1
--- MavenException.java 12 Apr 2003 00:02:05 -0000 1.4
+++ MavenException.java 3 Jan 2004 06:45:39 -0000 1.4.10.1
@@ -63,7 +63,6 @@
* The base class for all exceptions thrown by MavenSession. Taken liberally from
* <a href="http://jakarta.apache.org/ant/">Ant's</a> BuildException
*
- * @author dion
* @version $Id$
*/
public class MavenException extends Exception
No revision
No revision
1.3.4.3 +296 -297 maven/src/java/org/apache/maven/plugin/Attic/JellyPlugin.java
Index: JellyPlugin.java
===================================================================
RCS file: /home/cvs/maven/src/java/org/apache/maven/plugin/Attic/JellyPlugin.java,v
retrieving revision 1.3.4.2
retrieving revision 1.3.4.3
diff -u -r1.3.4.2 -r1.3.4.3
--- JellyPlugin.java 2 Dec 2003 03:59:06 -0000 1.3.4.2
+++ JellyPlugin.java 3 Jan 2004 06:45:40 -0000 1.3.4.3
@@ -1,297 +1,296 @@
-package org.apache.maven.plugin;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache Maven" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache Maven", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- *
- * ====================================================================
- */
-
-import com.werken.forehead.ForeheadClassLoader;
-import org.apache.commons.jelly.Script;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.apache.maven.MavenException;
-import org.apache.maven.MavenUtils;
-import org.apache.maven.jelly.JellyUtils;
-import org.apache.maven.jelly.MavenJellyContext;
-import org.apache.maven.project.Project;
-import org.apache.maven.util.Expand;
-
-import java.io.File;
-import java.io.IOException;
-
-/**
- * A runtime view of a plugin written in Jelly.
- *
- * @author dion
- * @author <a href="mailto:brett@apache.org">Brett Porter</a>
- * @version $Id$
- * @todo cleanup needed.
- */
-final class JellyPlugin
-{
- /** Logger. */
- private static final Log log = LogFactory.getLog( JellyPlugin.class );
-
- /** The plugin ID. This will be the artifact ID + version (not a usual ID.
- * @todo rename? [RC2]
- */
- private final String id;
-
- /** the jar file the plugin was extracted from. @todo [RC2] - needed? */
- private File jarFile;
-
- /** the directory to unpack the plugin into. @todo [RC2] - needed? */
- private File unpackDirectory;
-
- /** the directory the plugin is installed into. @todo [RC2] - needed? */
- private File directory;
-
- /** the project.xml file for the plugin */
- private File descriptor;
-
- /** the script for this plugin */
- private File scriptFile;
-
- /** Maven project for the plugin */
- private Project project;
-
- /** compiled script */
- private Script compiledScript;
-
- /** classloader for the plugin. @todo just lazy at the moment, refactor */
- private ForeheadClassLoader parentClassLoader;
-
- /**
- * Constructor.
- * @param pluginFile the JAR file to read the plugin from.
- */
- JellyPlugin(File pluginFile)
- {
- String directory = pluginFile.getName();
- int index = directory.indexOf( ".jar" );
- if ( index >= 0 )
- {
- this.id = directory.substring( 0, index );
- this.jarFile = pluginFile;
- }
- else
- {
- this.id = directory;
- }
- }
-
- /**
- * Get the plugin identifier.
- * @return the plugin identifier
- */
- String getId()
- {
- return id;
- }
-
- /**
- * Unpack the plugin.
- * @param unpackDirectory the directory to unpack the plugin to
- * @todo [RC2] refactor with new parameter
- * @throws MavenException if there was a problem unpacking
- */
- void unpack( File unpackDirectory ) throws MavenException
- {
- if ( jarFile == null )
- {
- return;
- }
-
- File unzipDir = new File( unpackDirectory, id );
-
- // if there's no directory, or the jar is newer, expand the jar
- if ( !unzipDir.exists() || ( jarFile.lastModified() > unzipDir.lastModified() ) )
- {
- if (log.isDebugEnabled())
- {
- log.debug( "Unpacking '" + id + "' plugin to directory --> " + unzipDir.getAbsolutePath() );
- }
- /** TODO [RC2] - reinstate for cache: cacheManager.invalidateCache(id); */
-
- try
- {
- Expand unzipper = new Expand();
- unzipper.setSrc( jarFile );
- unzipper.setDest( unzipDir );
- unzipper.execute();
- }
- catch ( IOException e )
- {
- throw new MavenException( "Unable to extract plugin: " + jarFile, e );
- }
- }
- }
-
- /**
- * Load the plugin.
- * @throws Exception the exception
- * @todo [RC2] this is ugly
- */
- void load() throws Exception
- {
- log.debug( "Loading plugin '" + id + "'" );
-
- project = MavenUtils.getProject( getDescriptor(), null, false );
- project.verifyDependencies();
- parentClassLoader.addURL(directory.toURL());
- PluginManager.processDependencies(project, parentClassLoader);
- }
-
- /**
- * @return the install directory of the plugin
- */
- public File getDirectory()
- {
- if (directory == null && unpackDirectory != null)
- {
- directory = new File(unpackDirectory, id);
- }
- return directory;
- }
-
- /**
- * @param aDirectory the install directory of the plugin
- */
- public void setDirectory(File aDirectory)
- {
- directory = aDirectory;
- }
-
- /**
- * @return true if a plugin.jelly exists in the directory
- */
- public boolean hasScript()
- {
- return getScriptFile().exists();
- }
-
- /**
- * @return the jelly script
- */
- public File getScriptFile()
- {
- if (scriptFile == null) {
- scriptFile = new File( getDirectory(), "plugin.jelly");
- }
- return scriptFile;
- }
-
- /**
- * @return the project descriptor for this plugin
- */
- public File getDescriptor()
- {
- if (descriptor == null) {
- descriptor = new File( getDirectory(), "project.xml");
- }
- return descriptor;
- }
-
- /**
- * @return the maven project for this plugin
- */
- public Project getProject()
- {
- return project;
- }
-
- /**
- * @param project a maven project
- */
- public void setProject(Project project)
- {
- this.project = project;
- }
-
- /**
- * Get a compiled plugin script for the plugin.
- * @param context the context to compile using
- * @return the script
- * @throws Exception FIXME bad
- */
- public Script getCompiledScriptFor(MavenJellyContext context) throws Exception
- {
- if (hasScript())
- {
- compiledScript = JellyUtils.compileScript(getScriptFile(), context);
- }
- return compiledScript;
- }
-
- /**
- * @param file the jar file containing the plugin
- */
- public void setJarFile(File file)
- {
- jarFile = file;
- }
-
- /**
- * @param file the directory to unpack the plugin into
- */
- public void setUnpackDirectory(File file)
- {
- unpackDirectory = file;
- }
-
- public void setParentClassLoader(ForeheadClassLoader loader)
- {
- parentClassLoader = loader;
- }
-}
+package org.apache.maven.plugin;
+
+/* ====================================================================
+ * The Apache Software License, Version 1.1
+ *
+ * Copyright (c) 2001 The Apache Software Foundation. All rights
+ * reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * 3. The end-user documentation included with the redistribution,
+ * if any, must include the following acknowledgment:
+ * "This product includes software developed by the
+ * Apache Software Foundation (http://www.apache.org/)."
+ * Alternately, this acknowledgment may appear in the software itself,
+ * if and wherever such third-party acknowledgments normally appear.
+ *
+ * 4. The names "Apache" and "Apache Software Foundation" and
+ * "Apache Maven" must not be used to endorse or promote products
+ * derived from this software without prior written permission. For
+ * written permission, please contact apache@apache.org.
+ *
+ * 5. Products derived from this software may not be called "Apache",
+ * "Apache Maven", nor may "Apache" appear in their name, without
+ * prior written permission of the Apache Software Foundation.
+ *
+ * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
+ * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
+ * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
+ * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ * ====================================================================
+ *
+ * This software consists of voluntary contributions made by many
+ * individuals on behalf of the Apache Software Foundation. For more
+ * information on the Apache Software Foundation, please see
+ * <http://www.apache.org/>.
+ *
+ * ====================================================================
+ */
+
+import com.werken.forehead.ForeheadClassLoader;
+import org.apache.commons.jelly.Script;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.maven.MavenException;
+import org.apache.maven.MavenUtils;
+import org.apache.maven.jelly.JellyUtils;
+import org.apache.maven.jelly.MavenJellyContext;
+import org.apache.maven.project.Project;
+import org.apache.maven.util.Expand;
+
+import java.io.File;
+import java.io.IOException;
+
+/**
+ * A runtime view of a plugin written in Jelly.
+ *
+ * @author <a href="mailto:brett@apache.org">Brett Porter</a>
+ * @version $Id$
+ * @todo cleanup needed.
+ */
+final class JellyPlugin
+{
+ /** Logger. */
+ private static final Log log = LogFactory.getLog( JellyPlugin.class );
+
+ /** The plugin ID. This will be the artifact ID + version (not a usual ID.
+ * @todo rename? [RC2]
+ */
+ private final String id;
+
+ /** the jar file the plugin was extracted from. @todo [RC2] - needed? */
+ private File jarFile;
+
+ /** the directory to unpack the plugin into. @todo [RC2] - needed? */
+ private File unpackDirectory;
+
+ /** the directory the plugin is installed into. @todo [RC2] - needed? */
+ private File directory;
+
+ /** the project.xml file for the plugin */
+ private File descriptor;
+
+ /** the script for this plugin */
+ private File scriptFile;
+
+ /** Maven project for the plugin */
+ private Project project;
+
+ /** compiled script */
+ private Script compiledScript;
+
+ /** classloader for the plugin. @todo just lazy at the moment, refactor */
+ private ForeheadClassLoader parentClassLoader;
+
+ /**
+ * Constructor.
+ * @param pluginFile the JAR file to read the plugin from.
+ */
+ JellyPlugin(File pluginFile)
+ {
+ String directory = pluginFile.getName();
+ int index = directory.indexOf( ".jar" );
+ if ( index >= 0 )
+ {
+ this.id = directory.substring( 0, index );
+ this.jarFile = pluginFile;
+ }
+ else
+ {
+ this.id = directory;
+ }
+ }
+
+ /**
+ * Get the plugin identifier.
+ * @return the plugin identifier
+ */
+ String getId()
+ {
+ return id;
+ }
+
+ /**
+ * Unpack the plugin.
+ * @param unpackDirectory the directory to unpack the plugin to
+ * @todo [RC2] refactor with new parameter
+ * @throws MavenException if there was a problem unpacking
+ */
+ void unpack( File unpackDirectory ) throws MavenException
+ {
+ if ( jarFile == null )
+ {
+ return;
+ }
+
+ File unzipDir = new File( unpackDirectory, id );
+
+ // if there's no directory, or the jar is newer, expand the jar
+ if ( !unzipDir.exists() || ( jarFile.lastModified() > unzipDir.lastModified() ) )
+ {
+ if (log.isDebugEnabled())
+ {
+ log.debug( "Unpacking '" + id + "' plugin to directory --> " + unzipDir.getAbsolutePath() );
+ }
+ /** TODO [RC2] - reinstate for cache: cacheManager.invalidateCache(id); */
+
+ try
+ {
+ Expand unzipper = new Expand();
+ unzipper.setSrc( jarFile );
+ unzipper.setDest( unzipDir );
+ unzipper.execute();
+ }
+ catch ( IOException e )
+ {
+ throw new MavenException( "Unable to extract plugin: " + jarFile, e );
+ }
+ }
+ }
+
+ /**
+ * Load the plugin.
+ * @throws Exception the exception
+ * @todo [RC2] this is ugly
+ */
+ void load() throws Exception
+ {
+ log.debug( "Loading plugin '" + id + "'" );
+
+ project = MavenUtils.getProject( getDescriptor(), null, false );
+ project.verifyDependencies();
+ parentClassLoader.addURL(directory.toURL());
+ PluginManager.processDependencies(project, parentClassLoader);
+ }
+
+ /**
+ * @return the install directory of the plugin
+ */
+ public File getDirectory()
+ {
+ if (directory == null && unpackDirectory != null)
+ {
+ directory = new File(unpackDirectory, id);
+ }
+ return directory;
+ }
+
+ /**
+ * @param aDirectory the install directory of the plugin
+ */
+ public void setDirectory(File aDirectory)
+ {
+ directory = aDirectory;
+ }
+
+ /**
+ * @return true if a plugin.jelly exists in the directory
+ */
+ public boolean hasScript()
+ {
+ return getScriptFile().exists();
+ }
+
+ /**
+ * @return the jelly script
+ */
+ public File getScriptFile()
+ {
+ if (scriptFile == null) {
+ scriptFile = new File( getDirectory(), "plugin.jelly");
+ }
+ return scriptFile;
+ }
+
+ /**
+ * @return the project descriptor for this plugin
+ */
+ public File getDescriptor()
+ {
+ if (descriptor == null) {
+ descriptor = new File( getDirectory(), "project.xml");
+ }
+ return descriptor;
+ }
+
+ /**
+ * @return the maven project for this plugin
+ */
+ public Project getProject()
+ {
+ return project;
+ }
+
+ /**
+ * @param project a maven project
+ */
+ public void setProject(Project project)
+ {
+ this.project = project;
+ }
+
+ /**
+ * Get a compiled plugin script for the plugin.
+ * @param context the context to compile using
+ * @return the script
+ * @throws Exception FIXME bad
+ */
+ public Script getCompiledScriptFor(MavenJellyContext context) throws Exception
+ {
+ if (hasScript())
+ {
+ compiledScript = JellyUtils.compileScript(getScriptFile(), context);
+ }
+ return compiledScript;
+ }
+
+ /**
+ * @param file the jar file containing the plugin
+ */
+ public void setJarFile(File file)
+ {
+ jarFile = file;
+ }
+
+ /**
+ * @param file the directory to unpack the plugin into
+ */
+ public void setUnpackDirectory(File file)
+ {
+ unpackDirectory = file;
+ }
+
+ public void setParentClassLoader(ForeheadClassLoader loader)
+ {
+ parentClassLoader = loader;
+ }
+}
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
RE: cvs commit:
maven/src/java/org/apache/maven/pluginJellyPlugin.java
Posted by Jason van Zyl <jv...@maven.org>.
On Sat, 2004-01-03 at 13:48, Stephane Nicoll wrote:
> I agree with you.
> However, what about cvs history?
Why should I have to use CVS history to glean one of the most useful
pieces of information to a source file. Not only is it important
information insofar as being able to ask questions but I always look at
@author tags as I can get a pretty good understanding of what I'm in for
by looking at the authors. I want to see that information as I often
make decisions whether to even try something based on who wrote it.
I'm not taking my @author tags out, I really don't care what anyone else
does. You can't force someone to put @author tags in the sources. I just
find it pointless to remove them. If someone really wants to be
anonymous and "do it all for the community" then they not just remove
their names from the sources but from everything if that's what they
believe. For myself, among everythign else I certainly do it for the
recognition and I want my name in there. Even on lots of the shit code
I've written I still want my name in there. But whatever, I think
removing @author tags is a ridiculous and silly idea. Whatever floats
your boat.
> --
> jvz.
>
> Jason van Zyl
> jason@zenplex.com
> http://tambora.zenplex.org
>
> In short, man creates for himself a new religion of a rational
> and technical order to justify his work and to be justified in it.
>
> -- Jacques Ellul, The Technological Society
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
RE: cvs commit:
maven/src/java/org/apache/maven/pluginJellyPlugin.java
Posted by Jason van Zyl <jv...@maven.org>.
On Sat, 2004-01-03 at 18:51, dion@multitask.com.au wrote:
> Lots of reasons. One being the sheer amount of spam I get from web
> collected email addresses.
>
> As far as author tags promoting code quality and accountability, that
> doesn't happen for me in practice,
But you just removed your tags so how much 'practice' have you had
really? At work it's different because you probably work with a very
small group of people, or an even smaller number on a per client basis.
I think in OSS where there can be a great number of contributors and
given that CVS history has been known to disappear the @author tags can
only be a good thing.
> and getting a history of a particular
> file is a piece of cake for anyone that uses an IDE, or knows CVS.
Provided the history is intact, yes.
> --
> dIon Gillard, Multitask Consulting
> Blog: http://blogs.codehaus.org/people/dion/
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
--
jvz.
Jason van Zyl
jason@zenplex.com
http://tambora.zenplex.org
In short, man creates for himself a new religion of a rational
and technical order to justify his work and to be justified in it.
-- Jacques Ellul, The Technological Society
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
RE: cvs commit: maven/src/java/org/apache/maven/pluginJellyPlugin.java
Posted by Vincent Massol <vm...@pivolis.com>.
> -----Original Message-----
> From: dion@multitask.com.au [mailto:dion@multitask.com.au]
> Sent: 04 January 2004 00:51
> To: Maven Developers List
> Subject: RE: cvs commit:
> maven/src/java/org/apache/maven/pluginJellyPlugin.java
>
> "Stephane Nicoll" <st...@skynet.be> wrote on 04/01/2004
05:48:18
> AM:
>
> > I agree with you.
> > However, what about cvs history?
> >
> > -----Message d'origine-----
> > De : Jason van Zyl [mailto:jvanzyl@maven.org]
> > Envoyé : samedi 3 janvier 2004 18:52
> > À : Maven Developers List
> > Objet : Re: cvs commit:
> > maven/src/java/org/apache/maven/pluginJellyPlugin.java
> >
> >
> > On Sat, 2004-01-03 at 01:45, dion@apache.org wrote:
> > > dion 2004/01/02 22:45:40
> > >
> > > Modified: src/java/org/apache/maven/jelly/tags/maven Tag:
> > > MAVEN-1_0-BRANCH ParamCheck.java
> UserCheck.java
> > > CopyResources.java PluginVarTag.java
> > > src/java/org/apache/maven/util Tag:
MAVEN-1_0-BRANCH
> > > DVSLFormatter.java
> > > src/test/java/org/apache/maven Tag:
MAVEN-1_0-BRANCH
> > > JAXPTest.java
> > > src/test/java/org/apache/maven/plugin Tag:
> MAVEN-1_0-BRANCH
> > > PluginManagerTest.java
> > > src/java/org/apache/maven/cli Tag: MAVEN-1_0-BRANCH
> > App.java
> > > src/java/org/apache/maven/project Tag:
MAVEN-1_0-BRANCH
> > > Project.java
> > > src/java/org/apache/maven Tag: MAVEN-1_0-BRANCH
> > > MavenException.java
> > > src/java/org/apache/maven/plugin Tag:
MAVEN-1_0-BRANCH
> > > JellyPlugin.java
> > > Log:
> > > Remove my @authors
> > >
> >
> > Why are you doing that? It makes it really hard to easily see who
has
> > done what which I personally find very valuable. I would actually
ask
> > that you put them back as I find it extremely annoying having
anonymous
> > sources as it doesn't promote any sort of code quality,
accountability
> > and leaves new comers resorting to scm commands to figure out who
did
> > what in the event they would actually like to ask any questions.
>
> Lots of reasons. One being the sheer amount of spam I get from web
> collected email addresses.
Why don't you use the "at" strategy? As in: "dion at multitask dot com"
for example?
WRT spam I have found that the best solution is to have a good anti-spam
tool. It works really great. I'm using Spambayes and it catches 100% of
my spam emails and almost no false positives (about 1 false positive put
in the "unsure spam" folder every 7 days - I get about 150 spam emails
per day, so it's not too bad at all).
-Vincent
>
> As far as author tags promoting code quality and accountability, that
> doesn't happen for me in practice, and getting a history of a
particular
> file is a piece of cake for anyone that uses an IDE, or knows CVS.
>
> --
> dIon Gillard, Multitask Consulting
> Blog: http://blogs.codehaus.org/people/dion/
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
RE: cvs commit: maven/src/java/org/apache/maven/pluginJellyPlugin.java
Posted by di...@multitask.com.au.
"Stephane Nicoll" <st...@skynet.be> wrote on 04/01/2004 05:48:18
AM:
> I agree with you.
> However, what about cvs history?
>
> -----Message d'origine-----
> De : Jason van Zyl [mailto:jvanzyl@maven.org]
> Envoyé : samedi 3 janvier 2004 18:52
> À : Maven Developers List
> Objet : Re: cvs commit:
> maven/src/java/org/apache/maven/pluginJellyPlugin.java
>
>
> On Sat, 2004-01-03 at 01:45, dion@apache.org wrote:
> > dion 2004/01/02 22:45:40
> >
> > Modified: src/java/org/apache/maven/jelly/tags/maven Tag:
> > MAVEN-1_0-BRANCH ParamCheck.java
UserCheck.java
> > CopyResources.java PluginVarTag.java
> > src/java/org/apache/maven/util Tag: MAVEN-1_0-BRANCH
> > DVSLFormatter.java
> > src/test/java/org/apache/maven Tag: MAVEN-1_0-BRANCH
> > JAXPTest.java
> > src/test/java/org/apache/maven/plugin Tag:
MAVEN-1_0-BRANCH
> > PluginManagerTest.java
> > src/java/org/apache/maven/cli Tag: MAVEN-1_0-BRANCH
> App.java
> > src/java/org/apache/maven/project Tag: MAVEN-1_0-BRANCH
> > Project.java
> > src/java/org/apache/maven Tag: MAVEN-1_0-BRANCH
> > MavenException.java
> > src/java/org/apache/maven/plugin Tag: MAVEN-1_0-BRANCH
> > JellyPlugin.java
> > Log:
> > Remove my @authors
> >
>
> Why are you doing that? It makes it really hard to easily see who has
> done what which I personally find very valuable. I would actually ask
> that you put them back as I find it extremely annoying having anonymous
> sources as it doesn't promote any sort of code quality, accountability
> and leaves new comers resorting to scm commands to figure out who did
> what in the event they would actually like to ask any questions.
Lots of reasons. One being the sheer amount of spam I get from web
collected email addresses.
As far as author tags promoting code quality and accountability, that
doesn't happen for me in practice, and getting a history of a particular
file is a piece of cake for anyone that uses an IDE, or knows CVS.
--
dIon Gillard, Multitask Consulting
Blog: http://blogs.codehaus.org/people/dion/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
RE: cvs commit: maven/src/java/org/apache/maven/pluginJellyPlugin.java
Posted by Stephane Nicoll <st...@skynet.be>.
I agree with you.
However, what about cvs history?
-----Message d'origine-----
De : Jason van Zyl [mailto:jvanzyl@maven.org]
Envoyé : samedi 3 janvier 2004 18:52
À : Maven Developers List
Objet : Re: cvs commit:
maven/src/java/org/apache/maven/pluginJellyPlugin.java
On Sat, 2004-01-03 at 01:45, dion@apache.org wrote:
> dion 2004/01/02 22:45:40
>
> Modified: src/java/org/apache/maven/jelly/tags/maven Tag:
> MAVEN-1_0-BRANCH ParamCheck.java UserCheck.java
> CopyResources.java PluginVarTag.java
> src/java/org/apache/maven/util Tag: MAVEN-1_0-BRANCH
> DVSLFormatter.java
> src/test/java/org/apache/maven Tag: MAVEN-1_0-BRANCH
> JAXPTest.java
> src/test/java/org/apache/maven/plugin Tag: MAVEN-1_0-BRANCH
> PluginManagerTest.java
> src/java/org/apache/maven/cli Tag: MAVEN-1_0-BRANCH
App.java
> src/java/org/apache/maven/project Tag: MAVEN-1_0-BRANCH
> Project.java
> src/java/org/apache/maven Tag: MAVEN-1_0-BRANCH
> MavenException.java
> src/java/org/apache/maven/plugin Tag: MAVEN-1_0-BRANCH
> JellyPlugin.java
> Log:
> Remove my @authors
>
Why are you doing that? It makes it really hard to easily see who has
done what which I personally find very valuable. I would actually ask
that you put them back as I find it extremely annoying having anonymous
sources as it doesn't promote any sort of code quality, accountability
and leaves new comers resorting to scm commands to figure out who did
what in the event they would actually like to ask any questions.
--
jvz.
Jason van Zyl
jason@zenplex.com
http://tambora.zenplex.org
In short, man creates for himself a new religion of a rational
and technical order to justify his work and to be justified in it.
-- Jacques Ellul, The Technological Society
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: cvs commit: maven/src/java/org/apache/maven/plugin
JellyPlugin.java
Posted by Jason van Zyl <jv...@maven.org>.
On Sat, 2004-01-03 at 01:45, dion@apache.org wrote:
> dion 2004/01/02 22:45:40
>
> Modified: src/java/org/apache/maven/jelly/tags/maven Tag:
> MAVEN-1_0-BRANCH ParamCheck.java UserCheck.java
> CopyResources.java PluginVarTag.java
> src/java/org/apache/maven/util Tag: MAVEN-1_0-BRANCH
> DVSLFormatter.java
> src/test/java/org/apache/maven Tag: MAVEN-1_0-BRANCH
> JAXPTest.java
> src/test/java/org/apache/maven/plugin Tag: MAVEN-1_0-BRANCH
> PluginManagerTest.java
> src/java/org/apache/maven/cli Tag: MAVEN-1_0-BRANCH App.java
> src/java/org/apache/maven/project Tag: MAVEN-1_0-BRANCH
> Project.java
> src/java/org/apache/maven Tag: MAVEN-1_0-BRANCH
> MavenException.java
> src/java/org/apache/maven/plugin Tag: MAVEN-1_0-BRANCH
> JellyPlugin.java
> Log:
> Remove my @authors
>
Why are you doing that? It makes it really hard to easily see who has
done what which I personally find very valuable. I would actually ask
that you put them back as I find it extremely annoying having anonymous
sources as it doesn't promote any sort of code quality, accountability
and leaves new comers resorting to scm commands to figure out who did
what in the event they would actually like to ask any questions.
--
jvz.
Jason van Zyl
jason@zenplex.com
http://tambora.zenplex.org
In short, man creates for himself a new religion of a rational
and technical order to justify his work and to be justified in it.
-- Jacques Ellul, The Technological Society
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org