mirror of
https://github.com/apache/maven-mvnd.git
synced 2025-10-14 14:10:52 +00:00
@@ -18,7 +18,7 @@
|
||||
*/
|
||||
package org.mvndaemon.mvnd.client;
|
||||
|
||||
import org.apache.maven.cli.MavenCli;
|
||||
import org.apache.maven.cling.MavenCling;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
@@ -26,8 +26,8 @@ public class DefaultClient {
|
||||
public static void main(String[] argv) throws Exception {
|
||||
final Logger LOGGER = LoggerFactory.getLogger(DefaultClient.class);
|
||||
LOGGER.warn("Found old JDK, fallback to the embedded maven!");
|
||||
LOGGER.warn("Use JDK 11+ to run maven-mvnd client!");
|
||||
LOGGER.warn("Use JDK 17+ to run maven-mvnd client!");
|
||||
|
||||
MavenCli.main(argv);
|
||||
MavenCling.main(argv);
|
||||
}
|
||||
}
|
||||
|
@@ -69,8 +69,6 @@ public class DefaultClient implements Client {
|
||||
|
||||
private static final Logger LOGGER = LoggerFactory.getLogger(DefaultClient.class);
|
||||
|
||||
private final DaemonParameters parameters;
|
||||
|
||||
public static void main(String[] argv) throws Exception {
|
||||
final List<String> args = new ArrayList<>(Arrays.asList(argv));
|
||||
|
||||
@@ -224,6 +222,8 @@ public class DefaultClient implements Client {
|
||||
.noneMatch(e -> e.hasCommandLineOption(Collections.singletonList(arg)));
|
||||
}
|
||||
|
||||
private final DaemonParameters parameters;
|
||||
|
||||
public DefaultClient(DaemonParameters parameters) {
|
||||
// Those options are needed in order to be able to set the environment correctly
|
||||
this.parameters = parameters.withJdkJavaOpts(
|
||||
@@ -484,7 +484,6 @@ public class DefaultClient implements Client {
|
||||
}
|
||||
|
||||
private DefaultResult(List<String> args, Exception exception, int exitCode) {
|
||||
super();
|
||||
this.args = args;
|
||||
this.exception = exception;
|
||||
this.exitCode = exitCode;
|
||||
|
@@ -46,7 +46,7 @@ import java.util.stream.Collectors;
|
||||
import java.util.stream.Stream;
|
||||
|
||||
import org.apache.maven.api.cli.extensions.CoreExtension;
|
||||
import org.apache.maven.cli.internal.extension.io.CoreExtensionsStaxReader;
|
||||
import org.apache.maven.cling.internal.extension.io.CoreExtensionsStaxReader;
|
||||
import org.mvndaemon.mvnd.common.Environment;
|
||||
import org.mvndaemon.mvnd.common.InterpolationHelper;
|
||||
import org.mvndaemon.mvnd.common.Os;
|
||||
|
Reference in New Issue
Block a user