diff --git a/src/main/java/org/apache/maven/plugins/install/InstallFileMojo.java b/src/main/java/org/apache/maven/plugins/install/InstallFileMojo.java index 86d87af9..a2cc7028 100644 --- a/src/main/java/org/apache/maven/plugins/install/InstallFileMojo.java +++ b/src/main/java/org/apache/maven/plugins/install/InstallFileMojo.java @@ -218,7 +218,7 @@ public void execute() throws MojoExecutionException, MojoFailureException { ArtifactType artifactType = repositorySystemSession.getArtifactTypeRegistry().get(packaging); if (artifactType != null - && StringUtils.isEmpty(classifier) + && (classifier == null || classifier.isEmpty()) && !StringUtils.isEmpty(artifactType.getClassifier())) { classifier = artifactType.getClassifier(); }