mirror of https://github.com/apache/maven.git
Fixing issue with different lifecycles getting in the way of one another, as when `mvn clean install` on a maven-plugin project catches the clean:clean binding from the clean lifecycle, and knocks out the plugin:descriptor binding from the beginning of the default lifecycle.
Plugins can now be built using maven trunk once again. git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@542734 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
38b12ace0c
commit
a866905cb4
|
@ -155,7 +155,8 @@ public class BuildPlan
|
||||||
List newRendered = new ArrayList( bindingsToAdd );
|
List newRendered = new ArrayList( bindingsToAdd );
|
||||||
|
|
||||||
// if we've already executed part of the lifecycle, just continue with the new bindings.
|
// if we've already executed part of the lifecycle, just continue with the new bindings.
|
||||||
if ( ( renderedLifecycleMojos != null ) && ( renderedLifecycleMojos.size() < bindingsToAdd.size() ) )
|
if ( ( renderedLifecycleMojos != null ) && ( renderedLifecycleMojos.size() < bindingsToAdd.size() )
|
||||||
|
&& bindingsToAdd.containsAll( renderedLifecycleMojos ) )
|
||||||
{
|
{
|
||||||
bindingsToAdd = bindingsToAdd.subList( renderedLifecycleMojos.size(), bindingsToAdd.size() );
|
bindingsToAdd = bindingsToAdd.subList( renderedLifecycleMojos.size(), bindingsToAdd.size() );
|
||||||
}
|
}
|
||||||
|
|
|
@ -71,6 +71,7 @@ public class DefaultBuildPlanner
|
||||||
throws LifecycleSpecificationException, LifecycleLoaderException
|
throws LifecycleSpecificationException, LifecycleLoaderException
|
||||||
{
|
{
|
||||||
List tasks = plan.getTasks();
|
List tasks = plan.getTasks();
|
||||||
|
|
||||||
for ( Iterator it = tasks.iterator(); it.hasNext(); )
|
for ( Iterator it = tasks.iterator(); it.hasNext(); )
|
||||||
{
|
{
|
||||||
String task = (String) it.next();
|
String task = (String) it.next();
|
||||||
|
|
|
@ -564,6 +564,7 @@
|
||||||
<field>
|
<field>
|
||||||
<name>groupId</name>
|
<name>groupId</name>
|
||||||
<required>true</required>
|
<required>true</required>
|
||||||
|
<identifier>true</identifier>
|
||||||
<version>1.0.0</version>
|
<version>1.0.0</version>
|
||||||
<description>Plugin's groupId.</description>
|
<description>Plugin's groupId.</description>
|
||||||
<type>String</type>
|
<type>String</type>
|
||||||
|
@ -571,6 +572,7 @@
|
||||||
<field>
|
<field>
|
||||||
<name>artifactId</name>
|
<name>artifactId</name>
|
||||||
<required>true</required>
|
<required>true</required>
|
||||||
|
<identifier>true</identifier>
|
||||||
<version>1.0.0</version>
|
<version>1.0.0</version>
|
||||||
<description>Plugin's artifactId.</description>
|
<description>Plugin's artifactId.</description>
|
||||||
<type>String</type>
|
<type>String</type>
|
||||||
|
@ -585,6 +587,7 @@
|
||||||
<field>
|
<field>
|
||||||
<name>goal</name>
|
<name>goal</name>
|
||||||
<required>true</required>
|
<required>true</required>
|
||||||
|
<identifier>true</identifier>
|
||||||
<version>1.0.0</version>
|
<version>1.0.0</version>
|
||||||
<description>Mojo's goal name.</description>
|
<description>Mojo's goal name.</description>
|
||||||
<type>String</type>
|
<type>String</type>
|
||||||
|
@ -592,6 +595,7 @@
|
||||||
<field>
|
<field>
|
||||||
<name>executionId</name>
|
<name>executionId</name>
|
||||||
<version>1.0.0</version>
|
<version>1.0.0</version>
|
||||||
|
<identifier>true</identifier>
|
||||||
<defaultValue>default</defaultValue>
|
<defaultValue>default</defaultValue>
|
||||||
<description>A name for this mojo binding, for purposes of merging configurations via inheritance, etc.</description>
|
<description>A name for this mojo binding, for purposes of merging configurations via inheritance, etc.</description>
|
||||||
<type>String</type>
|
<type>String</type>
|
||||||
|
@ -615,6 +619,7 @@
|
||||||
<type>boolean</type>
|
<type>boolean</type>
|
||||||
</field>
|
</field>
|
||||||
</fields>
|
</fields>
|
||||||
|
<!--
|
||||||
<codeSegments>
|
<codeSegments>
|
||||||
<codeSegment>
|
<codeSegment>
|
||||||
<version>1.0.0</version>
|
<version>1.0.0</version>
|
||||||
|
@ -627,6 +632,7 @@
|
||||||
]]></code>
|
]]></code>
|
||||||
</codeSegment>
|
</codeSegment>
|
||||||
</codeSegments>
|
</codeSegments>
|
||||||
|
-->
|
||||||
</class>
|
</class>
|
||||||
</classes>
|
</classes>
|
||||||
</model>
|
</model>
|
||||||
|
|
Loading…
Reference in New Issue