use of org.jboss.pnc.bacon.pig.impl.pnc.PncBuilder in project bacon by project-ncl.
the class PigFacade method cancel.
public static String cancel() {
ImportResult importResult = context().getPncImportResult();
if (importResult == null) {
importResult = readPncEntities();
}
PncBuilder builder = new PncBuilder();
return builder.cancelRunningGroupBuild(importResult.getBuildGroup().getId());
}
use of org.jboss.pnc.bacon.pig.impl.pnc.PncBuilder in project bacon by project-ncl.
the class PigFacade method build.
public static GroupBuildInfo build(boolean tempBuild, boolean tempBuildTS, RebuildMode rebuildMode, boolean wait, boolean dryRun) {
ImportResult importResult = context().getPncImportResult();
if (importResult == null) {
importResult = readPncEntities();
}
if (tempBuild) {
log.info("Temporary build");
}
try (PncBuilder pncBuilder = new PncBuilder()) {
GroupBuild groupBuild = pncBuilder.build(importResult.getBuildGroup(), tempBuild, tempBuildTS, rebuildMode, wait, dryRun);
if (wait) {
try (BuildInfoCollector buildInfoCollector = new BuildInfoCollector()) {
return buildInfoCollector.getBuildsFromGroupBuild(groupBuild);
}
}
log.info("Not waiting for build to finish.");
return null;
}
}
Aggregations