Get the cause of a maven build failure with Maven embedder

114 views Asked by At

I am able to run maven build with the following code

MavenCli mavenCli = new MavenCli();
int result = mavenCli.doMain(goals.toArray(new String[goals.size()]), pom, System.out, System.out);

Basically result is equal to 0 if build is successful, and 1 otherwise. Is there any way to get the cause of a build failure?

0

There are 0 answers