geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jdil...@apache.org
Subject svn commit: r484836 - /geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/mavenplugins/car/PackageMojo.java
Date Fri, 08 Dec 2006 23:06:28 GMT
Author: jdillon
Date: Fri Dec  8 15:06:25 2006
New Revision: 484836

URL: http://svn.apache.org/viewvc?view=rev&rev=484836
Log:
(GERONIMO-2411) ensure legal files are added

Modified:
    geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/mavenplugins/car/PackageMojo.java

Modified: geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/mavenplugins/car/PackageMojo.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/mavenplugins/car/PackageMojo.java?view=diff&rev=484836&r1=484835&r2=484836
==============================================================================
--- geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/mavenplugins/car/PackageMojo.java
(original)
+++ geronimo/server/trunk/maven-plugins/car-maven-plugin/src/main/java/org/apache/geronimo/mavenplugins/car/PackageMojo.java
Fri Dec  8 15:06:25 2006
@@ -96,7 +96,16 @@
      * @readonly
      */
     private JarArchiver jarArchiver = null;
-
+    
+    /**
+     * The module base directory.
+     *
+     * @parameter expression="${project.basedir}"
+     * @required
+     * @readonly
+     */
+    private File baseDirectory = null;
+    
     /**
      * Directory containing the generated archive.
      *
@@ -344,7 +353,25 @@
             if (classesDirectory.isDirectory()) {
                 archiver.getArchiver().addDirectory(classesDirectory);
             }
+            
+            //
+            // HACK: Include legal files here for sanity
+            //
+
+            //
+            // NOTE: Would be nice to share this with the copy-legal-files mojo
+            //
+            String[] includes = {
+                "LICENSE.txt",
+                "LICENSE",
+                "NOTICE.txt",
+                "NOTICE",
+                "DISCLAIMER.txt",
+                "DISCLAIMER"
+            };
 
+            archiver.getArchiver().addDirectory(baseDirectory, "META-INF/", includes, new
String[0]);
+            
             if (classpath != null) {
                 archive.addManifestEntry("Class-Path", getClassPath());
             }



Mime
View raw message