Uploaded image for project: 'Maven'
  1. Maven
  2. MNG-4342

[regression] Multiple goals within single execution with equally named parameter get configured with wrong default values

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 3.0-alpha-3
    • 3.0-alpha-3
    • Plugins and Lifecycle
    • None

    Description

      Take this example snippet:

      <plugin>
        <artifactId>maven-plugin-plugin</artifactId>
        <version>2.5</version>
        <executions>
          <execution>
            <phase>initialize</phase>
            <goals>
              <!-- NOTE: Both of these goals have an "outputDirectory" parameter but with different default values -->
              <goal>helpmojo</goal>
              <goal>descriptor</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      

      When running this with trunk, both mojos get configured with the same value for their outputDirectory parameter, i.e. the default value for one mojo pollutes the configuration of the other mojo such that one ends up with

      target/generated-sources/plugin/HelpMojo.java
      target/generated-sources/plugin/plugin.xml      <- this should have been generated in target/classes/META-INF/maven
      

      Attachments

        Activity

          People

            bentmann Benjamin Bentmann
            bentmann Benjamin Bentmann
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: