Maven 1.x Jar Plugin

Using maven.jar.manifest.classpath.add=true from maven console gives huge Class-Path

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: None
  • Fix Version/s: 1.8
  • Component/s: None
  • Labels:
    None
  • Number of attachments :
    0

Description

When running maven console on a JAR where the manifest classpath is set using maven.jar.manifest.classpath.add=true, the classpath string is not reset between runs. So, if running the jar goal multiple times, the Class-Path attribute will be getting longer and longer, containing multiple copies of the classpath.

This patch of plugin.jelly in maven-jar-plugin:
<j:set var="jarClasspath" value="${maven.jar.manifest.classpath.add}"/>
+ <j:set var="maven.jar.classpath" value=""/>
<j:if test="${jarClasspath}">

fixes the problem but I'm unsure if it will affect something else.

Issue Links

Activity

There are no comments yet on this issue.

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: