You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sling.apache.org by cz...@apache.org on 2021/06/09 10:15:40 UTC

[sling-slingfeature-maven-plugin] branch master updated: SLING-10475 : plugin's apis-jar goal fails for empty jar

This is an automated email from the ASF dual-hosted git repository.

cziegeler pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-slingfeature-maven-plugin.git


The following commit(s) were added to refs/heads/master by this push:
     new 1d768e9  SLING-10475 : plugin's apis-jar goal fails for empty jar
1d768e9 is described below

commit 1d768e9a226eeb6081f811523ab936bd803a7b58
Author: Carsten Ziegeler <cz...@apache.org>
AuthorDate: Wed Jun 9 12:15:29 2021 +0200

    SLING-10475 : plugin's apis-jar goal fails for empty jar
---
 src/main/java/org/apache/sling/feature/maven/mojos/ApisJarMojo.java | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/main/java/org/apache/sling/feature/maven/mojos/ApisJarMojo.java b/src/main/java/org/apache/sling/feature/maven/mojos/ApisJarMojo.java
index 9397e21..c7ea3e2 100644
--- a/src/main/java/org/apache/sling/feature/maven/mojos/ApisJarMojo.java
+++ b/src/main/java/org/apache/sling/feature/maven/mojos/ApisJarMojo.java
@@ -454,6 +454,8 @@ public class ApisJarMojo extends AbstractIncludingFeatureMojo {
         } else {
             getLog().debug("Starting APIs JARs creation...");
 
+            this.mainOutputDir.mkdirs();
+            
             for (final Feature feature : features) {
                 onFeature(feature);
             }
@@ -1647,7 +1649,6 @@ public class ApisJarMojo extends AbstractIncludingFeatureMojo {
 
         // replace/add manifest entries with the one provided in manifestProperties configuration
         archiveConfiguration.addManifestEntries(ctx.getConfig().getManifestEntries());
-
         final File target = new File(mainOutputDir, targetId.toMvnName());
         MavenArchiver archiver = new MavenArchiver();
         archiver.setArchiver(jarArchiver);