MCPcopy Create free account
hub / github.com/diffplug/goomph / directorApp

Method directorApp

src/main/java/com/diffplug/gradle/p2/P2Model.java:314–332  ·  view source on GitHub ↗

Returns the arguments required to call "eclipsec" and run the p2 director application to install the artifacts from the repos in this model into the given directory and profile.

(File dstFolder, String profile)

Source from the content-addressed store, hash-verified

312 * to install the artifacts from the repos in this model into the given directory and profile.
313 */
314 public DirectorApp directorApp(File dstFolder, String profile) {
315 return performWithoutMissingBundlePool(() -> {
316 DirectorApp builder = new DirectorApp();
317 builder.clean();
318 builder.consolelog();
319 repos.forEach(repo -> builder.addArg("repository", repo));
320 metadataRepos.forEach(repo -> builder.addArg("metadataRepository", repo));
321 artifactRepos.forEach(repo -> builder.addArg("artifactRepository", repo));
322 ius.forEach(iu -> builder.addArg("installIU", iu));
323 builder.addArg("profile", profile);
324 builder.addArg("destination", FileMisc.asUrl(dstFolder));
325 // deletes cached repository information, which will often include local paths
326 builder.doLast.add(() -> {
327 Path path = dstFolder.toPath().resolve("p2/org.eclipse.equinox.p2.engine/.settings");
328 FileUtils.deleteDirectory(path.toFile());
329 });
330 return builder;
331 });
332 }
333
334 /**
335 * An extension of EclipseApp with typed methods appropriate for p2 director.

Callers 6

mainMethod · 0.95
mainMethod · 0.95
testMethod · 0.95
ideSetupP2Method · 0.95
testDirectorArgsMethod · 0.80
obtainBootstrapMethod · 0.80

Calls 7

asUrlMethod · 0.95
consolelogMethod · 0.80
addArgMethod · 0.80
cleanMethod · 0.45
addMethod · 0.45
resolveMethod · 0.45

Tested by 4

mainMethod · 0.76
mainMethod · 0.76
testMethod · 0.76
testDirectorArgsMethod · 0.64