Uploaded image for project: 'Maven Dependency Plugin'
  1. Maven Dependency Plugin
  2. MDEP-629

Unpack goal with includes/excludes does not honor marker files

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 3.1.1
    • Fix Version/s: None
    • Component/s: unpack, unpack-dependencies
    • Labels:
      None

      Description

      When using the unpack goal to extract an artifact dependency, that action is performed regardless of any previous run which already created a marker file.

      Consider this pom extract:

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-dependency-plugin</artifactId>
        <version>3.1.1</version>
        <executions>
          <execution>
            <id>unpack</id>
            <phase>generate-sources</phase>
            <goals>
              <goal>unpack</goal>
            </goals>
            <configuration>
              <excludes>${my.excludes}</excludes>
              <artifactItems>
                <artifactItem>
                  <groupId>groupid</groupId>
                  <artifactId>artifactid</artifactId>
                  <type>war</type>            
                  <overWrite>false</overWrite>
                </artifactItem>
              </artifactItems>
            </configuration>
          </execution>
        </executions>
      </plugin>

      After executing "mvn generate-sources", the following marker file has been created:

      target/dependency-maven-plugin-markers/myartifactfile-1.01480985089

      Obviously, this file is not checked when this run is repeated.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              joergd Jörg Delker
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: