You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by sc...@apache.org on 2015/12/23 00:38:04 UTC

svn commit: r1721474 - /maven/plugins/trunk/maven-shade-plugin/src/main/java/org/apache/maven/plugins/shade/mojo/ShadeMojo.java

Author: schulte
Date: Tue Dec 22 23:38:04 2015
New Revision: 1721474

URL: http://svn.apache.org/viewvc?rev=1721474&view=rev
Log:
[MSHADE-195] createSourcesJar with source:jar-no-fork causes sources.jar to be deployed twice, causing the build to fail

o Updated to use correct source artifact type.


Modified:
    maven/plugins/trunk/maven-shade-plugin/src/main/java/org/apache/maven/plugins/shade/mojo/ShadeMojo.java

Modified: maven/plugins/trunk/maven-shade-plugin/src/main/java/org/apache/maven/plugins/shade/mojo/ShadeMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-shade-plugin/src/main/java/org/apache/maven/plugins/shade/mojo/ShadeMojo.java?rev=1721474&r1=1721473&r2=1721474&view=diff
==============================================================================
--- maven/plugins/trunk/maven-shade-plugin/src/main/java/org/apache/maven/plugins/shade/mojo/ShadeMojo.java (original)
+++ maven/plugins/trunk/maven-shade-plugin/src/main/java/org/apache/maven/plugins/shade/mojo/ShadeMojo.java Tue Dec 22 23:38:04 2015
@@ -495,7 +495,8 @@ public class ShadeMojo
                                                   outputJar );
                     if ( createSourcesJar )
                     {
-                        projectHelper.attachArtifact( project, "jar", shadedClassifierName + "-sources", sourcesJar );
+                        projectHelper.attachArtifact( project, "java-source", shadedClassifierName + "-sources",
+                                                      sourcesJar );
                     }
                 }
                 else if ( !renamed )
@@ -513,7 +514,7 @@ public class ShadeMojo
 
                             replaceFile( shadedSources, sourcesJar );
 
-                            projectHelper.attachArtifact( project, "jar", "sources", shadedSources );
+                            projectHelper.attachArtifact( project, "java-source", "sources", shadedSources );
                         }
 
                         if ( shadeTestJar )