use of org.gradle.process.internal.CurrentProcess in project gradle by gradle.
the class BuildEnvironmentBuilder method buildAll.
@Override
public Object buildAll(String modelName, Project target) {
File gradleUserHomeDir = target.getGradle().getGradleUserHomeDir();
String gradleVersion = target.getGradle().getGradleVersion();
CurrentProcess currentProcess = new CurrentProcess();
File javaHome = currentProcess.getJvm().getJavaHome();
List<String> jvmArgs = currentProcess.getJvmOptions().getAllImmutableJvmArgs();
DefaultBuildIdentifier buildIdentifier = new DefaultBuildIdentifier(target.getRootDir());
return new DefaultBuildEnvironment(buildIdentifier, gradleUserHomeDir, gradleVersion, javaHome, jvmArgs);
}
Aggregations