From 7286e853ae8bd69f63ec23a11afbc0fdea9bf1e9 Mon Sep 17 00:00:00 2001 From: Milos Kleint Date: Wed, 20 Sep 2006 06:37:40 +0000 Subject: [PATCH] put a resolved parent artifact in the final mavenproject instance git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@448095 13f79535-47bb-0310-9956-ffa450edef68 --- .../apache/maven/project/DefaultMavenProjectBuilder.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/maven-project/src/main/java/org/apache/maven/project/DefaultMavenProjectBuilder.java b/maven-project/src/main/java/org/apache/maven/project/DefaultMavenProjectBuilder.java index 1cee6b5c84..ede9c01a5d 100644 --- a/maven-project/src/main/java/org/apache/maven/project/DefaultMavenProjectBuilder.java +++ b/maven-project/src/main/java/org/apache/maven/project/DefaultMavenProjectBuilder.java @@ -891,6 +891,8 @@ public class DefaultMavenProjectBuilder MavenProject parentProject = project.getParent(); Model originalModel = project.getOriginalModel(); + + Artifact parentArtifact = project.getParentArtifact(); // We will return a different project object using the new model (hence the need to return a project, not just modify the parameter) project = new MavenProject( model ); @@ -923,9 +925,10 @@ public class DefaultMavenProjectBuilder if ( parentProject != null ) { - Artifact parentArtifact = artifactFactory.createParentArtifact( parentProject.getGroupId(), - parentProject.getArtifactId(), - parentProject.getVersion() ); +// Artifact parentArtifact = artifactFactory.createParentArtifact( parentProject.getGroupId(), +// parentProject.getArtifactId(), +// parentProject.getVersion() ); + // the parent artifact from the parameter passed project instance is resolved. project.setParentArtifact( parentArtifact ); }