Uploaded image for project: 'Maven Assembly Plugin'
  1. Maven Assembly Plugin
  2. MASSEMBLY-607

Wildcard in dependencySet/includes doesn't match artifact with empty classifier

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 2.3
    • None
    • dependencySet
    • None
    • Windows 7/Maven 3.0.03

    Description

      Following dependency set will match only my jar artifacts with any non-empty classifier:

              <dependencySet>
                  <includes>
                      <include>com.mycompany.*:*:jar:*:*</include>
                  </includes>
              </dependencySet>
      

      But it seems wildcard should include empty ones.

      Here is the related code fragment:

      .m2repositoryorgapachemavensharedmaven-common-artifact-filters1.4maven-common-artifact-filters-1.4.jar!orgapachemavensharedartifactfilterPatternIncludesArtifactFilter.class
      172    private boolean matchAgainst( final String value, final List patterns, final boolean regionMatch )
      
      181            // fail immediately if pattern tokens outnumber tokens to match
      182            boolean matched = ( patternTokens.length <= tokens.length );
      
      

      I have following values achieving 182 line:
      pattern=[com.mycompany.*, *, jar, *, *]
      tokens=[com.mycompany, myproject, jar, 1.0.0-SNAPSHOT]

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              akormushin Alexander Kormushin
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated: