getLog().info("Webapp directory not present. Assuming that there is no webapp. Skip processing webapp " + webapp.getCanonicalPath());
return;
}
//create a simplified pom with logic in the validate-phase (other phases may fail because of the simplification) and use it as pom of the project.
MavenModelBooster model = new MavenModelBooster();
model.readModelFromXml(ProcessWebappMojo.class.getResourceAsStream("processWebapp-pom.xml"));
model.replaceProjectHeader(project);
String filename = "temp-processWebapp-pom.xml";
File file = new File(project.getBasedir(), filename );
getLog().info("writing file: "+ file);
model.writeModelToXmlfile(file);
//invoke validate on the pom
String command = "cmd /c mvn --file \""+file.getCanonicalPath() + "\" validate";
getLog().info(command);
LoggingOutputStream output = new LoggingOutputStream(getLog());