Java Code Examples for org.gradle.StartParameter#newInstance()
The following examples show how to use
org.gradle.StartParameter#newInstance() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: SettingsHandler.java From pushfish-android with BSD 2-Clause "Simplified" License | 6 votes |
public SettingsInternal findAndLoadSettings(GradleInternal gradle) { StartParameter startParameter = gradle.getStartParameter(); SettingsInternal settings = findSettingsAndLoadIfAppropriate(gradle, startParameter); ProjectSpec spec = ProjectSpecs.forStartParameter(startParameter, settings); if (spec.containsProject(settings.getProjectRegistry())) { setDefaultProject(spec, settings); return settings; } // Try again with empty settings StartParameter noSearchParameter = startParameter.newInstance(); noSearchParameter.useEmptySettings(); settings = findSettingsAndLoadIfAppropriate(gradle, noSearchParameter); // Set explicit build file, if required if (noSearchParameter.getBuildFile() != null) { ProjectDescriptor rootProject = settings.getRootProject(); rootProject.setBuildFileName(noSearchParameter.getBuildFile().getName()); } setDefaultProject(spec, settings); return settings; }
Example 2
Source File: SettingsHandler.java From Pushjet-Android with BSD 2-Clause "Simplified" License | 6 votes |
public SettingsInternal findAndLoadSettings(GradleInternal gradle) { StartParameter startParameter = gradle.getStartParameter(); SettingsInternal settings = findSettingsAndLoadIfAppropriate(gradle, startParameter); ProjectSpec spec = ProjectSpecs.forStartParameter(startParameter, settings); if (spec.containsProject(settings.getProjectRegistry())) { setDefaultProject(spec, settings); return settings; } // Try again with empty settings StartParameter noSearchParameter = startParameter.newInstance(); noSearchParameter.useEmptySettings(); settings = findSettingsAndLoadIfAppropriate(gradle, noSearchParameter); // Set explicit build file, if required if (noSearchParameter.getBuildFile() != null) { ProjectDescriptor rootProject = settings.getRootProject(); rootProject.setBuildFileName(noSearchParameter.getBuildFile().getName()); } setDefaultProject(spec, settings); return settings; }
Example 3
Source File: BuildSourceBuilder.java From pushfish-android with BSD 2-Clause "Simplified" License | 5 votes |
private GradleLauncher buildGradleLauncher(StartParameter startParameter) { final StartParameter startParameterArg = startParameter.newInstance(); startParameterArg.setProjectProperties(startParameter.getProjectProperties()); startParameterArg.setSearchUpwards(false); startParameterArg.setProfile(startParameter.isProfile()); return gradleLauncherFactory.newInstance(startParameterArg, cancellationToken); }
Example 4
Source File: BuildSourceBuilder.java From pushfish-android with BSD 2-Clause "Simplified" License | 5 votes |
private GradleLauncher buildGradleLauncher(StartParameter startParameter) { final StartParameter startParameterArg = startParameter.newInstance(); startParameterArg.setProjectProperties(startParameter.getProjectProperties()); startParameterArg.setSearchUpwards(false); startParameterArg.setProfile(startParameter.isProfile()); return gradleLauncherFactory.newInstance(startParameterArg); }
Example 5
Source File: BuildSourceBuilder.java From Pushjet-Android with BSD 2-Clause "Simplified" License | 5 votes |
private GradleLauncher buildGradleLauncher(StartParameter startParameter) { final StartParameter startParameterArg = startParameter.newInstance(); startParameterArg.setProjectProperties(startParameter.getProjectProperties()); startParameterArg.setSearchUpwards(false); startParameterArg.setProfile(startParameter.isProfile()); return gradleLauncherFactory.newInstance(startParameterArg, cancellationToken); }
Example 6
Source File: BuildSourceBuilder.java From Pushjet-Android with BSD 2-Clause "Simplified" License | 5 votes |
private GradleLauncher buildGradleLauncher(StartParameter startParameter) { final StartParameter startParameterArg = startParameter.newInstance(); startParameterArg.setProjectProperties(startParameter.getProjectProperties()); startParameterArg.setSearchUpwards(false); startParameterArg.setProfile(startParameter.isProfile()); return gradleLauncherFactory.newInstance(startParameterArg); }