You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by el...@apache.org on 2025/12/22 11:15:58 UTC
(maven-jdeprscan-plugin) branch uti created (now 57191a8)
This is an automated email from the ASF dual-hosted git repository.
elharo pushed a change to branch uti
in repository https://gitbox.apache.org/repos/asf/maven-jdeprscan-plugin.git
at 57191a8 Prefer JDK methods
This branch includes the following new commits:
new 57191a8 Prefer JDK methods
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
(maven-jdeprscan-plugin) 01/01: Prefer JDK methods
Posted by el...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
elharo pushed a commit to branch uti
in repository https://gitbox.apache.org/repos/asf/maven-jdeprscan-plugin.git
commit 57191a834652ccdd8c01e2e44d130a654366f40a
Author: Elliotte Rusty Harold <el...@ibiblio.org>
AuthorDate: Mon Dec 22 06:15:48 2025 -0500
Prefer JDK methods
---
.../java/org/apache/maven/plugins/jdeprscan/BaseJDeprScanMojo.java | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/src/main/java/org/apache/maven/plugins/jdeprscan/BaseJDeprScanMojo.java b/src/main/java/org/apache/maven/plugins/jdeprscan/BaseJDeprScanMojo.java
index 29a3b26..ff97c0b 100644
--- a/src/main/java/org/apache/maven/plugins/jdeprscan/BaseJDeprScanMojo.java
+++ b/src/main/java/org/apache/maven/plugins/jdeprscan/BaseJDeprScanMojo.java
@@ -24,6 +24,7 @@ import java.nio.file.Path;
import java.util.Collection;
import java.util.Map;
import java.util.Set;
+import java.util.stream.Collectors;
import org.apache.maven.artifact.DependencyResolutionRequiredException;
import org.apache.maven.plugin.MojoExecutionException;
@@ -32,7 +33,6 @@ import org.apache.maven.plugins.annotations.Parameter;
import org.apache.maven.plugins.jdeprscan.consumers.JDeprScanConsumer;
import org.apache.maven.project.MavenProject;
import org.apache.maven.toolchain.ToolchainManager;
-import org.codehaus.plexus.util.StringUtils;
import org.codehaus.plexus.util.cli.CommandLineUtils.StringStreamConsumer;
import org.codehaus.plexus.util.cli.Commandline;
@@ -109,8 +109,8 @@ public abstract class BaseJDeprScanMojo extends AbstractJDeprScanMojo {
if (!cp.isEmpty()) {
cmd.createArg().setValue("--class-path");
-
- cmd.createArg().setValue(StringUtils.join(cp.iterator(), File.pathSeparator));
+ String classpath = cp.stream().map(Path::toString).collect(Collectors.joining(File.pathSeparator));
+ cmd.createArg().setValue(classpath);
}
} catch (DependencyResolutionRequiredException e) {