diff --git a/maven-core/src/main/java/org/apache/maven/lifecycle/DefaultLifecycleExecutor.java b/maven-core/src/main/java/org/apache/maven/lifecycle/DefaultLifecycleExecutor.java index 3f8a377321..8e3d9f4899 100644 --- a/maven-core/src/main/java/org/apache/maven/lifecycle/DefaultLifecycleExecutor.java +++ b/maven-core/src/main/java/org/apache/maven/lifecycle/DefaultLifecycleExecutor.java @@ -970,7 +970,9 @@ public class DefaultLifecycleExecutor { MavenProject project = session.getCurrentProject(); - Artifact artifact = repositorySystem.createArtifact( project.getGroupId(), project.getArtifactId(), project.getVersion(), null, project.getPackaging() ); + Artifact artifact = + repositorySystem.createProjectArtifact( project.getGroupId(), project.getArtifactId(), project.getVersion() ); + artifact.setFile( project.getFile() ); ArtifactFilter filter = new ScopeArtifactFilter( scope );