Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Uses Maven Artifact class instead of Aether Artifact to properly resolve dependencies #274

Merged
merged 1 commit into from
Apr 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@
*/
package com.akathist.maven.plugins.launch4j;

import org.apache.maven.artifact.Artifact;
import org.apache.maven.plugins.annotations.Parameter;
import org.eclipse.aether.artifact.Artifact;

import java.util.ArrayList;
import java.util.Arrays;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,7 @@ private void doExecute() throws MojoExecutionException {
getLog().debug("Overwriting config file property 'outfile' (='" + c.getOutfile().getAbsolutePath() + "') with local value '" + outfile.getAbsolutePath() + "'");
c.setOutfile(outfile);
}

if (icon != null) {
c.setIcon(icon);
}
Expand Down Expand Up @@ -445,10 +445,7 @@ private void doExecute() throws MojoExecutionException {
c.setVariables(vars);

if (classPath != null) {
Set<Artifact> newArtifacts = dependencies.stream().map(old ->
new DefaultArtifact(old.getGroupId(), old.getArtifactId(), old.getClassifier(), null, old.getVersion())
).collect(Collectors.toSet());
c.setClassPath(classPath.toL4j(newArtifacts));
c.setClassPath(classPath.toL4j(dependencies));
}
if (jre != null) {
jre.deprecationWarning(getLog());
Expand Down