mirror of https://github.com/apache/maven.git
o Improved location tracking
git-svn-id: https://svn.apache.org/repos/asf/maven/maven-3/trunk@1072163 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
ad9b6eba2a
commit
88349565ec
|
@ -126,6 +126,7 @@ public class DefaultInheritanceAssembler
|
||||||
{
|
{
|
||||||
// NOTE: Enforce recursive merge to trigger merging/inheritance logic for executions
|
// NOTE: Enforce recursive merge to trigger merging/inheritance logic for executions
|
||||||
Plugin plugin = new Plugin();
|
Plugin plugin = new Plugin();
|
||||||
|
plugin.setLocation( "", element.getLocation( "" ) );
|
||||||
plugin.setGroupId( null );
|
plugin.setGroupId( null );
|
||||||
mergePlugin( plugin, element, sourceDominant, context );
|
mergePlugin( plugin, element, sourceDominant, context );
|
||||||
|
|
||||||
|
@ -208,6 +209,7 @@ public class DefaultInheritanceAssembler
|
||||||
{
|
{
|
||||||
// NOTE: Enforce recursive merge to trigger merging/inheritance logic for executions as well
|
// NOTE: Enforce recursive merge to trigger merging/inheritance logic for executions as well
|
||||||
ReportPlugin plugin = new ReportPlugin();
|
ReportPlugin plugin = new ReportPlugin();
|
||||||
|
plugin.setLocation( "", element.getLocation( "" ) );
|
||||||
plugin.setGroupId( null );
|
plugin.setGroupId( null );
|
||||||
mergeReportPlugin( plugin, element, sourceDominant, context );
|
mergeReportPlugin( plugin, element, sourceDominant, context );
|
||||||
|
|
||||||
|
|
|
@ -120,12 +120,13 @@ public class MavenModelMerger
|
||||||
Map<Object, Object> context )
|
Map<Object, Object> context )
|
||||||
{
|
{
|
||||||
Organization src = source.getOrganization();
|
Organization src = source.getOrganization();
|
||||||
if ( source.getOrganization() != null )
|
if ( src != null )
|
||||||
{
|
{
|
||||||
Organization tgt = target.getOrganization();
|
Organization tgt = target.getOrganization();
|
||||||
if ( tgt == null )
|
if ( tgt == null )
|
||||||
{
|
{
|
||||||
tgt = new Organization();
|
tgt = new Organization();
|
||||||
|
tgt.setLocation( "", src.getLocation( "" ) );
|
||||||
target.setOrganization( tgt );
|
target.setOrganization( tgt );
|
||||||
mergeOrganization( tgt, src, sourceDominant, context );
|
mergeOrganization( tgt, src, sourceDominant, context );
|
||||||
}
|
}
|
||||||
|
@ -137,12 +138,13 @@ public class MavenModelMerger
|
||||||
Map<Object, Object> context )
|
Map<Object, Object> context )
|
||||||
{
|
{
|
||||||
IssueManagement src = source.getIssueManagement();
|
IssueManagement src = source.getIssueManagement();
|
||||||
if ( source.getIssueManagement() != null )
|
if ( src != null )
|
||||||
{
|
{
|
||||||
IssueManagement tgt = target.getIssueManagement();
|
IssueManagement tgt = target.getIssueManagement();
|
||||||
if ( tgt == null )
|
if ( tgt == null )
|
||||||
{
|
{
|
||||||
tgt = new IssueManagement();
|
tgt = new IssueManagement();
|
||||||
|
tgt.setLocation( "", src.getLocation( "" ) );
|
||||||
target.setIssueManagement( tgt );
|
target.setIssueManagement( tgt );
|
||||||
mergeIssueManagement( tgt, src, sourceDominant, context );
|
mergeIssueManagement( tgt, src, sourceDominant, context );
|
||||||
}
|
}
|
||||||
|
@ -154,12 +156,13 @@ public class MavenModelMerger
|
||||||
Map<Object, Object> context )
|
Map<Object, Object> context )
|
||||||
{
|
{
|
||||||
CiManagement src = source.getCiManagement();
|
CiManagement src = source.getCiManagement();
|
||||||
if ( source.getCiManagement() != null )
|
if ( src != null )
|
||||||
{
|
{
|
||||||
CiManagement tgt = target.getCiManagement();
|
CiManagement tgt = target.getCiManagement();
|
||||||
if ( tgt == null )
|
if ( tgt == null )
|
||||||
{
|
{
|
||||||
tgt = new CiManagement();
|
tgt = new CiManagement();
|
||||||
|
tgt.setLocation( "", src.getLocation( "" ) );
|
||||||
target.setCiManagement( tgt );
|
target.setCiManagement( tgt );
|
||||||
mergeCiManagement( tgt, src, sourceDominant, context );
|
mergeCiManagement( tgt, src, sourceDominant, context );
|
||||||
}
|
}
|
||||||
|
@ -367,6 +370,7 @@ public class MavenModelMerger
|
||||||
if ( sourceDominant || tgt == null )
|
if ( sourceDominant || tgt == null )
|
||||||
{
|
{
|
||||||
tgt = new DeploymentRepository();
|
tgt = new DeploymentRepository();
|
||||||
|
tgt.setLocation( "", src.getLocation( "" ) );
|
||||||
target.setRepository( tgt );
|
target.setRepository( tgt );
|
||||||
mergeDeploymentRepository( tgt, src, sourceDominant, context );
|
mergeDeploymentRepository( tgt, src, sourceDominant, context );
|
||||||
}
|
}
|
||||||
|
@ -386,6 +390,7 @@ public class MavenModelMerger
|
||||||
if ( sourceDominant || tgt == null )
|
if ( sourceDominant || tgt == null )
|
||||||
{
|
{
|
||||||
tgt = new DeploymentRepository();
|
tgt = new DeploymentRepository();
|
||||||
|
tgt.setLocation( "", src.getLocation( "" ) );
|
||||||
target.setSnapshotRepository( tgt );
|
target.setSnapshotRepository( tgt );
|
||||||
mergeDeploymentRepository( tgt, src, sourceDominant, context );
|
mergeDeploymentRepository( tgt, src, sourceDominant, context );
|
||||||
}
|
}
|
||||||
|
@ -403,6 +408,7 @@ public class MavenModelMerger
|
||||||
if ( sourceDominant || tgt == null )
|
if ( sourceDominant || tgt == null )
|
||||||
{
|
{
|
||||||
tgt = new Site();
|
tgt = new Site();
|
||||||
|
tgt.setLocation( "", src.getLocation( "" ) );
|
||||||
target.setSite( tgt );
|
target.setSite( tgt );
|
||||||
mergeSite( tgt, src, sourceDominant, context );
|
mergeSite( tgt, src, sourceDominant, context );
|
||||||
}
|
}
|
||||||
|
|
|
@ -155,7 +155,7 @@ public class ModelMerger
|
||||||
protected void mergeModel_Parent( Model target, Model source, boolean sourceDominant, Map<Object, Object> context )
|
protected void mergeModel_Parent( Model target, Model source, boolean sourceDominant, Map<Object, Object> context )
|
||||||
{
|
{
|
||||||
Parent src = source.getParent();
|
Parent src = source.getParent();
|
||||||
if ( source.getParent() != null )
|
if ( src != null )
|
||||||
{
|
{
|
||||||
Parent tgt = target.getParent();
|
Parent tgt = target.getParent();
|
||||||
if ( tgt == null )
|
if ( tgt == null )
|
||||||
|
@ -281,7 +281,7 @@ public class ModelMerger
|
||||||
Map<Object, Object> context )
|
Map<Object, Object> context )
|
||||||
{
|
{
|
||||||
Organization src = source.getOrganization();
|
Organization src = source.getOrganization();
|
||||||
if ( source.getOrganization() != null )
|
if ( src != null )
|
||||||
{
|
{
|
||||||
Organization tgt = target.getOrganization();
|
Organization tgt = target.getOrganization();
|
||||||
if ( tgt == null )
|
if ( tgt == null )
|
||||||
|
@ -409,7 +409,7 @@ public class ModelMerger
|
||||||
Map<Object, Object> context )
|
Map<Object, Object> context )
|
||||||
{
|
{
|
||||||
IssueManagement src = source.getIssueManagement();
|
IssueManagement src = source.getIssueManagement();
|
||||||
if ( source.getIssueManagement() != null )
|
if ( src != null )
|
||||||
{
|
{
|
||||||
IssueManagement tgt = target.getIssueManagement();
|
IssueManagement tgt = target.getIssueManagement();
|
||||||
if ( tgt == null )
|
if ( tgt == null )
|
||||||
|
@ -424,7 +424,7 @@ public class ModelMerger
|
||||||
protected void mergeModel_Scm( Model target, Model source, boolean sourceDominant, Map<Object, Object> context )
|
protected void mergeModel_Scm( Model target, Model source, boolean sourceDominant, Map<Object, Object> context )
|
||||||
{
|
{
|
||||||
Scm src = source.getScm();
|
Scm src = source.getScm();
|
||||||
if ( source.getScm() != null )
|
if ( src != null )
|
||||||
{
|
{
|
||||||
Scm tgt = target.getScm();
|
Scm tgt = target.getScm();
|
||||||
if ( tgt == null )
|
if ( tgt == null )
|
||||||
|
@ -440,7 +440,7 @@ public class ModelMerger
|
||||||
Map<Object, Object> context )
|
Map<Object, Object> context )
|
||||||
{
|
{
|
||||||
CiManagement src = source.getCiManagement();
|
CiManagement src = source.getCiManagement();
|
||||||
if ( source.getCiManagement() != null )
|
if ( src != null )
|
||||||
{
|
{
|
||||||
CiManagement tgt = target.getCiManagement();
|
CiManagement tgt = target.getCiManagement();
|
||||||
if ( tgt == null )
|
if ( tgt == null )
|
||||||
|
@ -456,7 +456,7 @@ public class ModelMerger
|
||||||
Map<Object, Object> context )
|
Map<Object, Object> context )
|
||||||
{
|
{
|
||||||
Prerequisites src = source.getPrerequisites();
|
Prerequisites src = source.getPrerequisites();
|
||||||
if ( source.getPrerequisites() != null )
|
if ( src != null )
|
||||||
{
|
{
|
||||||
Prerequisites tgt = target.getPrerequisites();
|
Prerequisites tgt = target.getPrerequisites();
|
||||||
if ( tgt == null )
|
if ( tgt == null )
|
||||||
|
@ -471,7 +471,7 @@ public class ModelMerger
|
||||||
protected void mergeModel_Build( Model target, Model source, boolean sourceDominant, Map<Object, Object> context )
|
protected void mergeModel_Build( Model target, Model source, boolean sourceDominant, Map<Object, Object> context )
|
||||||
{
|
{
|
||||||
Build src = source.getBuild();
|
Build src = source.getBuild();
|
||||||
if ( source.getBuild() != null )
|
if ( src != null )
|
||||||
{
|
{
|
||||||
Build tgt = target.getBuild();
|
Build tgt = target.getBuild();
|
||||||
if ( tgt == null )
|
if ( tgt == null )
|
||||||
|
@ -626,7 +626,7 @@ public class ModelMerger
|
||||||
Map<Object, Object> context )
|
Map<Object, Object> context )
|
||||||
{
|
{
|
||||||
DistributionManagement src = source.getDistributionManagement();
|
DistributionManagement src = source.getDistributionManagement();
|
||||||
if ( source.getDistributionManagement() != null )
|
if ( src != null )
|
||||||
{
|
{
|
||||||
DistributionManagement tgt = target.getDistributionManagement();
|
DistributionManagement tgt = target.getDistributionManagement();
|
||||||
if ( tgt == null )
|
if ( tgt == null )
|
||||||
|
@ -642,7 +642,7 @@ public class ModelMerger
|
||||||
Map<Object, Object> context )
|
Map<Object, Object> context )
|
||||||
{
|
{
|
||||||
Reporting src = source.getReporting();
|
Reporting src = source.getReporting();
|
||||||
if ( source.getReporting() != null )
|
if ( src != null )
|
||||||
{
|
{
|
||||||
Reporting tgt = target.getReporting();
|
Reporting tgt = target.getReporting();
|
||||||
if ( tgt == null )
|
if ( tgt == null )
|
||||||
|
@ -658,7 +658,7 @@ public class ModelMerger
|
||||||
Map<Object, Object> context )
|
Map<Object, Object> context )
|
||||||
{
|
{
|
||||||
DependencyManagement src = source.getDependencyManagement();
|
DependencyManagement src = source.getDependencyManagement();
|
||||||
if ( source.getDependencyManagement() != null )
|
if ( src != null )
|
||||||
{
|
{
|
||||||
DependencyManagement tgt = target.getDependencyManagement();
|
DependencyManagement tgt = target.getDependencyManagement();
|
||||||
if ( tgt == null )
|
if ( tgt == null )
|
||||||
|
@ -2440,7 +2440,7 @@ public class ModelMerger
|
||||||
boolean sourceDominant, Map<Object, Object> context )
|
boolean sourceDominant, Map<Object, Object> context )
|
||||||
{
|
{
|
||||||
PluginManagement src = source.getPluginManagement();
|
PluginManagement src = source.getPluginManagement();
|
||||||
if ( source.getPluginManagement() != null )
|
if ( src != null )
|
||||||
{
|
{
|
||||||
PluginManagement tgt = target.getPluginManagement();
|
PluginManagement tgt = target.getPluginManagement();
|
||||||
if ( tgt == null )
|
if ( tgt == null )
|
||||||
|
|
Loading…
Reference in New Issue