I\'m trying to create an intelliJ plugin that needs to execute maven targets on the current project. All the talk in the intertubes recommends using the MavenEmbedder. Goo
Dependency list for Maven Embedded 3.6.3 version that works in my Spring Boot 2.3 project (JDK8 or JDK 11 runtime):
org.apache.maven
maven-embedder
3.6.3
org.apache.maven
maven-compat
3.6.3
org.apache.maven.wagon
wagon-http
3.3.4
org.eclipse.aether
aether-connector-basic
1.1.0
runtime
org.eclipse.aether
aether-transport-wagon
1.1.0
runtime
org.slf4j
slf4j-simple
1.7.30
org.usefultoys
slf4j-toys
1.6.3
The Maven CLI command looks like to:
// Maven CLI to execute Maven Commands
MavenCli cli = new MavenCli();
int result = cli.doMain(args, workingDirectory,
org.usefultoys.slf4j.LoggerFactory.getInfoPrintStream(LOGGER),
org.usefultoys.slf4j.LoggerFactory.getErrorPrintStream(LOGGER));
HTH