in app-maven-plugin/src/main/java/com/google/cloud/tools/maven/stage/AppEngineWebXmlStager.java [50:75]
public void stage() throws MojoExecutionException {
AppEngineWebXmlProjectStageConfiguration config = configBuilder.buildConfiguration();
Path stagingDirectory = config.getStagingDirectory();
stageMojo.getLog().info("Staging the application to: " + stagingDirectory);
stageMojo.getLog().info("Detected App Engine appengine-web.xml based application.");
// delete staging directory if it exists
if (Files.exists(stagingDirectory)) {
stageMojo.getLog().info("Deleting the staging directory: " + stagingDirectory);
try {
FileUtils.deleteDirectory(stagingDirectory.toFile());
} catch (IOException ex) {
throw new MojoExecutionException("Unable to delete staging directory.", ex);
}
}
if (!stagingDirectory.toFile().mkdir()) {
throw new MojoExecutionException("Unable to create staging directory");
}
try {
stageMojo.getAppEngineFactory().appengineWebXmlStaging().stageStandard(config);
} catch (AppEngineException ex) {
throw new RuntimeException(ex);
}
}