Search in sources :

Example 1 with Sync

use of org.gradle.api.tasks.Sync in project gradle by gradle.

the class DistributionPlugin method addInstallTask.

private void addInstallTask(final Project project, final Distribution distribution) {
    String taskName = TASK_INSTALL_NAME;
    if (!MAIN_DISTRIBUTION_NAME.equals(distribution.getName())) {
        taskName = "install" + StringGroovyMethods.capitalize(distribution.getName()) + "Dist";
    }
    Sync installTask = project.getTasks().create(taskName, Sync.class);
    installTask.setDescription("Installs the project as a distribution as-is.");
    installTask.setGroup(DISTRIBUTION_GROUP);
    installTask.with(distribution.getContents());
    installTask.into(new Callable<File>() {

        @Override
        public File call() throws Exception {
            return project.file("" + project.getBuildDir() + "/install/" + distribution.getBaseName());
        }
    });
}
Also used : Sync(org.gradle.api.tasks.Sync) File(java.io.File) GradleException(org.gradle.api.GradleException)

Example 2 with Sync

use of org.gradle.api.tasks.Sync in project gradle by gradle.

the class OsgiPlugin method apply.

public void apply(final Project project) {
    project.getPluginManager().apply(JavaBasePlugin.class);
    final OsgiPluginConvention osgiConvention = new OsgiPluginConvention((ProjectInternal) project);
    project.getConvention().getPlugins().put("osgi", osgiConvention);
    project.getPlugins().withType(JavaPlugin.class, new Action<JavaPlugin>() {

        @Override
        public void execute(JavaPlugin javaPlugin) {
            // When creating the OSGi manifest, we must have a single view of all of the classes included in the jar.
            Sync prepareOsgiClasses = project.getTasks().create("osgiClasses", Sync.class);
            FileCollection classes = project.getConvention().getPlugin(JavaPluginConvention.class).getSourceSets().getByName("main").getOutput().getClassesDirs();
            File singleClassesDirectory = new File(project.getBuildDir(), "osgi-classes");
            prepareOsgiClasses.setDescription("Prepares a single classes directory required for OSGi analysis.");
            prepareOsgiClasses.from(classes);
            prepareOsgiClasses.into(singleClassesDirectory);
            Jar jarTask = (Jar) project.getTasks().getByName("jar");
            jarTask.dependsOn(prepareOsgiClasses);
            OsgiManifest osgiManifest = osgiConvention.osgiManifest();
            osgiManifest.setClassesDir(singleClassesDirectory);
            osgiManifest.setClasspath(project.getConfigurations().getByName("runtime"));
            jarTask.setManifest(osgiManifest);
        }
    });
}
Also used : JavaPluginConvention(org.gradle.api.plugins.JavaPluginConvention) JavaPlugin(org.gradle.api.plugins.JavaPlugin) Jar(org.gradle.api.tasks.bundling.Jar) Sync(org.gradle.api.tasks.Sync) FileCollection(org.gradle.api.file.FileCollection) File(java.io.File)

Example 3 with Sync

use of org.gradle.api.tasks.Sync in project spring-boot by spring-projects.

the class BomExtension method effectiveBomArtifact.

public void effectiveBomArtifact() {
    Configuration effectiveBomConfiguration = this.project.getConfigurations().create("effectiveBom");
    this.project.getTasks().matching((task) -> task.getName().equals(DeployedPlugin.GENERATE_POM_TASK_NAME)).all((task) -> {
        Sync syncBom = this.project.getTasks().create("syncBom", Sync.class);
        syncBom.dependsOn(task);
        File generatedBomDir = new File(this.project.getBuildDir(), "generated/bom");
        syncBom.setDestinationDir(generatedBomDir);
        syncBom.from(((GenerateMavenPom) task).getDestination(), (pom) -> pom.rename((name) -> "pom.xml"));
        try {
            String settingsXmlContent = FileCopyUtils.copyToString(new InputStreamReader(getClass().getClassLoader().getResourceAsStream("effective-bom-settings.xml"), StandardCharsets.UTF_8)).replace("localRepositoryPath", new File(this.project.getBuildDir(), "local-m2-repository").getAbsolutePath());
            syncBom.from(this.project.getResources().getText().fromString(settingsXmlContent), (settingsXml) -> settingsXml.rename((name) -> "settings.xml"));
        } catch (IOException ex) {
            throw new GradleException("Failed to prepare settings.xml", ex);
        }
        MavenExec generateEffectiveBom = this.project.getTasks().create("generateEffectiveBom", MavenExec.class);
        generateEffectiveBom.setProjectDir(generatedBomDir);
        File effectiveBom = new File(this.project.getBuildDir(), "generated/effective-bom/" + this.project.getName() + "-effective-bom.xml");
        generateEffectiveBom.args("--settings", "settings.xml", "help:effective-pom", "-Doutput=" + effectiveBom);
        generateEffectiveBom.dependsOn(syncBom);
        generateEffectiveBom.getOutputs().file(effectiveBom);
        generateEffectiveBom.doLast(new StripUnrepeatableOutputAction(effectiveBom));
        this.project.getArtifacts().add(effectiveBomConfiguration.getName(), effectiveBom, (artifact) -> artifact.builtBy(generateEffectiveBom));
    });
}
Also used : StreamResult(javax.xml.transform.stream.StreamResult) Closure(groovy.lang.Closure) InvalidUserCodeException(org.gradle.api.InvalidUserCodeException) Task(org.gradle.api.Task) Document(org.w3c.dom.Document) Map(java.util.Map) GroovyObjectSupport(groovy.lang.GroovyObjectSupport) Project(org.gradle.api.Project) Group(org.springframework.boot.build.bom.Library.Group) Collectors(java.util.stream.Collectors) StandardCharsets(java.nio.charset.StandardCharsets) List(java.util.List) DocumentBuilderFactory(javax.xml.parsers.DocumentBuilderFactory) FileCopyUtils(org.springframework.util.FileCopyUtils) MavenExec(org.springframework.boot.build.mavenplugin.MavenExec) DOMSource(javax.xml.transform.dom.DOMSource) InvalidVersionSpecificationException(org.apache.maven.artifact.versioning.InvalidVersionSpecificationException) LibraryVersion(org.springframework.boot.build.bom.Library.LibraryVersion) Module(org.springframework.boot.build.bom.Library.Module) XPath(javax.xml.xpath.XPath) DependencyVersions(org.springframework.boot.build.bom.Library.DependencyVersions) XPathConstants(javax.xml.xpath.XPathConstants) TaskExecutionException(org.gradle.api.tasks.TaskExecutionException) HashMap(java.util.HashMap) ArrayList(java.util.ArrayList) LinkedHashMap(java.util.LinkedHashMap) Inject(javax.inject.Inject) Configuration(org.gradle.api.artifacts.Configuration) Sync(org.gradle.api.tasks.Sync) DependencyHandler(org.gradle.api.artifacts.dsl.DependencyHandler) Exclusion(org.springframework.boot.build.bom.Library.Exclusion) VersionAlignment(org.springframework.boot.build.bom.Library.VersionAlignment) ProhibitedVersion(org.springframework.boot.build.bom.Library.ProhibitedVersion) DependencyLockDependencyVersions(org.springframework.boot.build.bom.Library.DependencyLockDependencyVersions) NodeList(org.w3c.dom.NodeList) Action(org.gradle.api.Action) JavaPlatformPlugin(org.gradle.api.plugins.JavaPlatformPlugin) IOException(java.io.IOException) DeployedPlugin(org.springframework.boot.build.DeployedPlugin) InputStreamReader(java.io.InputStreamReader) File(java.io.File) XPathFactory(javax.xml.xpath.XPathFactory) GenerateMavenPom(org.gradle.api.publish.maven.tasks.GenerateMavenPom) DependencyConstraintsDependencyVersions(org.springframework.boot.build.bom.Library.DependencyConstraintsDependencyVersions) DependencyVersion(org.springframework.boot.build.bom.bomr.version.DependencyVersion) ObjectFactory(org.gradle.api.model.ObjectFactory) GradleException(org.gradle.api.GradleException) TransformerFactory(javax.xml.transform.TransformerFactory) VersionRange(org.apache.maven.artifact.versioning.VersionRange) InvalidUserDataException(org.gradle.api.InvalidUserDataException) MavenExec(org.springframework.boot.build.mavenplugin.MavenExec) Configuration(org.gradle.api.artifacts.Configuration) InputStreamReader(java.io.InputStreamReader) GradleException(org.gradle.api.GradleException) IOException(java.io.IOException) Sync(org.gradle.api.tasks.Sync) File(java.io.File)

Example 4 with Sync

use of org.gradle.api.tasks.Sync in project gradle by gradle.

the class GradleUserManualPlugin method generateUserManual.

private void generateUserManual(Project project, TaskContainer tasks, ProjectLayout layout, GradleDocumentationExtension extension) {
    tasks.withType(AsciidoctorTask.class).configureEach(task -> {
        if (task.getName().equals("asciidoctor")) {
            // ignore this task
            task.setEnabled(false);
            return;
        }
        task.outputOptions(options -> {
            options.setSeparateOutputDirs(false);
            options.setBackends(singletonList("html5"));
        });
        // TODO: Break the paths assumed here
        TaskInputs inputs = task.getInputs();
        inputs.files(extension.getCssFiles()).withPropertyName("manual").withPathSensitivity(PathSensitivity.RELATIVE);
        inputs.dir("src/main/resources").withPropertyName("resources").withPathSensitivity(PathSensitivity.RELATIVE);
        inputs.dir(extension.getUserManual().getSnippets()).withPropertyName("snippets").withPathSensitivity(PathSensitivity.RELATIVE);
        inputs.dir(extension.getUserManual().getSamples()).withPropertyName("samples").withPathSensitivity(PathSensitivity.RELATIVE);
        Provider<Directory> stylesDir = extension.getUserManual().getStagedDocumentation().dir("css");
        inputs.dir(stylesDir).withPropertyName("stylesdir").withPathSensitivity(PathSensitivity.RELATIVE);
        // TODO: Break the paths assumed here
        Map<String, Object> attributes = new HashMap<>();
        // TODO: This breaks the provider
        attributes.put("stylesdir", stylesDir.get().getAsFile().getAbsolutePath());
        attributes.put("stylesheet", "manual.css");
        attributes.put("doctype", "book");
        attributes.put("imagesdir", "img");
        attributes.put("nofooter", true);
        attributes.put("sectanchors", true);
        attributes.put("sectlinks", true);
        attributes.put("linkattrs", true);
        attributes.put("reproducible", "");
        attributes.put("docinfo", "");
        attributes.put("lang", "en-US");
        attributes.put("encoding", "utf-8");
        attributes.put("idprefix", "");
        attributes.put("website", "https://gradle.org");
        // TODO: This breaks the provider
        attributes.put("javaApi", extension.getJavadocs().getJavaApi().get().toString());
        attributes.put("jdkDownloadUrl", "https://jdk.java.net/");
        // TODO: This is coupled to extension.getJavadocs().getJavaApi()
        attributes.put("javadocReferenceUrl", "https://docs.oracle.com/javase/8/docs/technotes/tools/windows/javadoc.html");
        // TODO: This is coupled to extension.getJavadocs().getJavaApi()
        attributes.put("minJdkVersion", "8");
        attributes.put("antManual", "https://ant.apache.org/manual");
        attributes.put("docsUrl", "https://docs.gradle.org");
        // TODO: This breaks if the version is changed later.
        attributes.put("gradleVersion", project.getVersion().toString());
        attributes.put("snippetsPath", "snippets");
        // Make sure the 'raw' location of the samples is available in all AsciidoctorTasks to access files with expected outputs in the 'tests' folder for inclusion in READMEs
        attributes.put("samplesPath", extension.getUserManual().getStagingRoot().dir("raw/samples").get().getAsFile());
        task.attributes(attributes);
    });
    TaskProvider<GenerateDocInfo> generateDocinfo = tasks.register("generateDocInfo", GenerateDocInfo.class, task -> {
        task.getDocumentationFiles().from(extension.getUserManual().getRoot());
        task.getDocumentationRoot().convention(extension.getUserManual().getRoot());
        task.getDestinationDirectory().convention(layout.getBuildDirectory().dir("tmp/" + task.getName()));
    });
    TaskProvider<Sync> userguideFlattenSources = tasks.register("stageUserguideSource", Sync.class, task -> {
        task.setDuplicatesStrategy(DuplicatesStrategy.FAIL);
        // TODO: This doesn't allow adoc files to be generated?
        task.from(extension.getUserManual().getRoot(), sub -> {
            sub.include("**/*.adoc");
            // Flatten adocs into a single directory
            sub.eachFile(fcd -> fcd.setRelativePath(RelativePath.parse(true, fcd.getName())));
        });
        // From the snippets and the samples, filter out files generated if the build contained was ever executed
        task.from(extension.getUserManual().getSnippets(), sub -> {
            sub.into("snippets");
            sub.exclude("**/.gradle/**");
            sub.exclude("**/build/**");
            sub.setIncludeEmptyDirs(false);
        });
        task.from(extension.getUserManual().getSamples(), sub -> {
            sub.into("samples");
            sub.exclude("**/*.adoc");
            sub.exclude("**/.gradle/**");
            sub.exclude("**/build/**");
            sub.setIncludeEmptyDirs(false);
        });
        task.from(extension.getCssFiles(), sub -> sub.into("css"));
        task.from(extension.getUserManual().getRoot().dir("img"), sub -> {
            sub.include("**/*.png", "**/*.gif", "**/*.jpg", "**/*.svg");
            sub.into("img");
        });
        task.from(extension.getUserManual().getResources());
        task.from(generateDocinfo);
        // TODO: This should be available on a Copy task.
        DirectoryProperty flattenedAsciidocDirectory = project.getObjects().directoryProperty();
        flattenedAsciidocDirectory.set(extension.getUserManual().getStagingRoot().dir("raw"));
        task.getOutputs().dir(flattenedAsciidocDirectory);
        task.getExtensions().getExtraProperties().set("destinationDirectory", flattenedAsciidocDirectory);
        task.into(flattenedAsciidocDirectory);
    });
    TaskProvider<AsciidoctorTask> userguideSinglePageHtml = tasks.register("userguideSinglePageHtml", AsciidoctorTask.class, task -> {
        task.setDescription("Generates HTML single-page user manual.");
        configureForUserGuideSinglePage(task, extension, project);
        task.outputOptions(options -> options.setBackends(singletonList("html5")));
        // TODO: This breaks the provider
        task.setOutputDir(extension.getUserManual().getStagingRoot().dir("render-single-html").get().getAsFile());
    });
    TaskProvider<AsciidoctorTask> userguideSinglePagePdf = tasks.register("userguideSinglePagePdf", AsciidoctorTask.class, task -> {
        task.setDescription("Generates PDF single-page user manual.");
        configureForUserGuideSinglePage(task, extension, project);
        task.outputOptions(options -> options.setBackends(singletonList("pdf")));
        // TODO: This breaks the provider
        task.setOutputDir(extension.getUserManual().getStagingRoot().dir("render-single-pdf").get().getAsFile());
    });
    TaskProvider<AsciidoctorTask> userguideMultiPage = tasks.register("userguideMultiPage", AsciidoctorTask.class, task -> {
        task.setGroup("documentation");
        task.setDescription("Generates multi-page user manual.");
        task.dependsOn(extension.getUserManual().getStagedDocumentation());
        task.sources(patternSet -> {
            patternSet.include("**/*.adoc");
            patternSet.exclude("javaProject*Layout.adoc");
            patternSet.exclude("userguide_single.adoc");
            patternSet.exclude("snippets/**/*.adoc");
        });
        // TODO: This breaks the provider
        task.setSourceDir(extension.getUserManual().getStagedDocumentation().get().getAsFile());
        // TODO: This breaks the provider
        task.setOutputDir(extension.getUserManual().getStagingRoot().dir("render-multi").get().getAsFile());
        Map<String, Object> attributes = new HashMap<>();
        attributes.put("icons", "font");
        attributes.put("source-highlighter", "prettify");
        attributes.put("toc", "auto");
        attributes.put("toclevels", 1);
        attributes.put("toc-title", "Contents");
        attributes.put("groovyDslPath", "../dsl");
        attributes.put("javadocPath", "../javadoc");
        attributes.put("kotlinDslPath", "https://gradle.github.io/kotlin-dsl-docs/api");
        // Used by SampleIncludeProcessor from `gradle/dotorg-docs`
        // TODO: This breaks the provider
        // TODO:
        attributes.put("samples-dir", extension.getUserManual().getStagedDocumentation().get().getAsFile());
        task.attributes(attributes);
    });
    // Avoid overlapping outputs by copying exactly what we want from other intermediate tasks
    TaskProvider<Sync> userguide = tasks.register("userguide", Sync.class, task -> {
        task.setGroup("documentation");
        task.setDescription("Stages rendered user manual documentation.");
        task.from(userguideSinglePageHtml);
        task.from(userguideSinglePagePdf);
        task.from(userguideMultiPage);
        task.into(extension.getUserManual().getStagingRoot().dir("final"));
        // TODO: Eliminate this duplication with the flatten task
        task.from(extension.getUserManual().getRoot().dir("img"), sub -> {
            sub.include("**/*.png", "**/*.gif", "**/*.jpg", "**/*.svg");
            sub.into("img");
        });
        task.rename("userguide_single.pdf", "userguide.pdf");
    });
    extension.userManual(userManual -> {
        userManual.getRoot().convention(extension.getSourceRoot().dir("userguide"));
        userManual.getStagingRoot().convention(extension.getStagingRoot().dir("usermanual"));
        // TODO: These should be generated too
        userManual.getSnippets().convention(layout.getProjectDirectory().dir("src/snippets"));
        userManual.getSamples().convention(layout.getProjectDirectory().dir("src/samples"));
        userManual.getStagedDocumentation().convention(userguideFlattenSources.flatMap(task -> (DirectoryProperty) task.getExtensions().getExtraProperties().get("destinationDirectory")));
        userManual.getRenderedDocumentation().from(userguide);
    });
}
Also used : HashMap(java.util.HashMap) ArrayList(java.util.ArrayList) Collections.singletonList(java.util.Collections.singletonList) LifecycleBasePlugin(org.gradle.language.base.plugins.LifecycleBasePlugin) Provider(org.gradle.api.provider.Provider) RelativePath(org.gradle.api.file.RelativePath) Sync(org.gradle.api.tasks.Sync) AsciidoctorTask(org.asciidoctor.gradle.jvm.AsciidoctorTask) TaskProvider(org.gradle.api.tasks.TaskProvider) DirectoryProperty(org.gradle.api.file.DirectoryProperty) SourceSetContainer(org.gradle.api.tasks.SourceSetContainer) Arrays.asList(java.util.Arrays.asList) PathSensitivity(org.gradle.api.tasks.PathSensitivity) Map(java.util.Map) DuplicatesStrategy(org.gradle.api.file.DuplicatesStrategy) Collections.singletonMap(java.util.Collections.singletonMap) Directory(org.gradle.api.file.Directory) TaskInputs(org.gradle.api.tasks.TaskInputs) Project(org.gradle.api.Project) List(java.util.List) ProjectLayout(org.gradle.api.file.ProjectLayout) TaskContainer(org.gradle.api.tasks.TaskContainer) GenerateApiMapping(gradlebuild.docs.dsl.source.GenerateApiMapping) GenerateDefaultImports(gradlebuild.docs.dsl.source.GenerateDefaultImports) Plugin(org.gradle.api.Plugin) HashMap(java.util.HashMap) TaskInputs(org.gradle.api.tasks.TaskInputs) DirectoryProperty(org.gradle.api.file.DirectoryProperty) Sync(org.gradle.api.tasks.Sync) AsciidoctorTask(org.asciidoctor.gradle.jvm.AsciidoctorTask) Directory(org.gradle.api.file.Directory)

Example 5 with Sync

use of org.gradle.api.tasks.Sync in project gradle by gradle.

the class XCTestConventionPlugin method configureTestSuiteBuildingTasks.

private void configureTestSuiteBuildingTasks(final Project project, final DefaultSwiftXCTestBinary binary) {
    // Overwrite the source to exclude `LinuxMain.swift`
    SwiftCompile compile = binary.getCompileTask().get();
    compile.getSource().setFrom(binary.getSwiftSource().getAsFileTree().matching(patterns -> patterns.include("**/*").exclude("**/LinuxMain.swift")));
    if (binary instanceof SwiftXCTestBundle) {
        TaskContainer tasks = project.getTasks();
        final Names names = binary.getNames();
        // TODO - creating a bundle should be done by some general purpose plugin
        // TODO - make this lazy
        final DefaultNativePlatform currentPlatform = new DefaultNativePlatform("current");
        final ModelRegistry modelRegistry = ((ProjectInternal) project).getModelRegistry();
        final NativeToolChain toolChain = modelRegistry.realize("toolChains", NativeToolChainRegistryInternal.class).getForPlatform(currentPlatform);
        // Platform specific arguments
        // TODO: Need to lazily configure compile task
        // TODO: Ultimately, this should be some kind of 3rd party dependency that's visible to dependency management.
        compile.getCompilerArgs().addAll(project.provider(() -> {
            File platformSdkPath = sdkPlatformPathLocator.find();
            File frameworkDir = new File(platformSdkPath, "Developer/Library/Frameworks");
            // Since Xcode 11/12, the XCTest framework is being replaced by a different library that's available in the sdk root
            File extraInclude = new File(platformSdkPath, "Developer/usr/lib");
            return Arrays.asList("-parse-as-library", "-F" + frameworkDir.getAbsolutePath(), "-I", extraInclude.getAbsolutePath(), "-v");
        }));
        // Add a link task
        final TaskProvider<LinkMachOBundle> link = tasks.register(names.getTaskName("link"), LinkMachOBundle.class, task -> {
            task.getLinkerArgs().set(project.provider(() -> {
                File platformSdkPath = sdkPlatformPathLocator.find();
                File frameworkDir = new File(platformSdkPath, "Developer/Library/Frameworks");
                // Since Xcode 11/12, the XCTest framework is being replaced by a different library that's available in the sdk root
                File extraInclude = new File(platformSdkPath, "Developer/usr/lib");
                return Lists.newArrayList("-F" + frameworkDir.getAbsolutePath(), "-L", extraInclude.getAbsolutePath(), "-framework", "XCTest", "-Xlinker", "-rpath", "-Xlinker", "@executable_path/../Frameworks", "-Xlinker", "-rpath", "-Xlinker", "@loader_path/../Frameworks");
            }));
            task.source(binary.getObjects());
            task.lib(binary.getLinkLibraries());
            final PlatformToolProvider toolProvider = ((NativeToolChainInternal) toolChain).select(currentPlatform);
            Provider<RegularFile> exeLocation = project.getLayout().getBuildDirectory().file(binary.getBaseName().map(baseName -> toolProvider.getExecutableName("exe/" + names.getDirName() + baseName)));
            task.getLinkedFile().set(exeLocation);
            task.getTargetPlatform().set(currentPlatform);
            task.getToolChain().set(toolChain);
            task.getDebuggable().set(binary.isDebuggable());
        });
        final TaskProvider<InstallXCTestBundle> install = tasks.register(names.getTaskName("install"), InstallXCTestBundle.class, task -> {
            task.getBundleBinaryFile().set(link.get().getLinkedFile());
            task.getInstallDirectory().set(project.getLayout().getBuildDirectory().dir("install/" + names.getDirName()));
        });
        binary.getInstallDirectory().set(install.flatMap(task -> task.getInstallDirectory()));
        binary.getExecutableFile().set(link.flatMap(task -> task.getLinkedFile()));
        DefaultSwiftXCTestBundle bundle = (DefaultSwiftXCTestBundle) binary;
        bundle.getLinkTask().set(link);
        bundle.getRunScriptFile().set(install.flatMap(task -> task.getRunScriptFile()));
    } else {
        DefaultSwiftXCTestExecutable executable = (DefaultSwiftXCTestExecutable) binary;
        executable.getRunScriptFile().set(executable.getInstallTask().flatMap(task -> task.getRunScriptFile()));
        // Rename `LinuxMain.swift` to `main.swift` so the entry point is correctly detected by swiftc
        if (binary.getTargetMachine().getOperatingSystemFamily().isLinux()) {
            TaskProvider<Sync> renameLinuxMainTask = project.getTasks().register("renameLinuxMain", Sync.class, task -> {
                task.from(binary.getSwiftSource());
                task.into(project.provider(() -> task.getTemporaryDir()));
                task.include("LinuxMain.swift");
                task.rename(it -> "main.swift");
            });
            compile.getSource().from(project.files(renameLinuxMainTask).getAsFileTree().matching(patterns -> patterns.include("**/*.swift")));
        }
    }
}
Also used : ConfigurableFileCollection(org.gradle.api.file.ConfigurableFileCollection) Arrays(java.util.Arrays) UnexportMainSymbol(org.gradle.language.nativeplatform.tasks.UnexportMainSymbol) NativeToolChainRegistryInternal(org.gradle.nativeplatform.toolchain.internal.NativeToolChainRegistryInternal) ProductionSwiftComponent(org.gradle.language.swift.ProductionSwiftComponent) DefaultSwiftXCTestExecutable(org.gradle.nativeplatform.test.xctest.internal.DefaultSwiftXCTestExecutable) GUtil(org.gradle.util.internal.GUtil) Provider(org.gradle.api.provider.Provider) ModelRegistry(org.gradle.model.internal.registry.ModelRegistry) DefaultNativePlatform(org.gradle.nativeplatform.platform.internal.DefaultNativePlatform) DefaultSwiftXCTestSuite(org.gradle.nativeplatform.test.xctest.internal.DefaultSwiftXCTestSuite) TaskProvider(org.gradle.api.tasks.TaskProvider) XCTest(org.gradle.nativeplatform.test.xctest.tasks.XCTest) TargetMachineFactory(org.gradle.nativeplatform.TargetMachineFactory) SwiftXCTestBundle(org.gradle.nativeplatform.test.xctest.SwiftXCTestBundle) ProjectInternal(org.gradle.api.internal.project.ProjectInternal) SwiftBasePlugin(org.gradle.language.swift.plugins.SwiftBasePlugin) PlatformToolProvider(org.gradle.nativeplatform.toolchain.internal.PlatformToolProvider) ImmutableAttributesFactory(org.gradle.api.internal.attributes.ImmutableAttributesFactory) Project(org.gradle.api.Project) TargetMachine(org.gradle.nativeplatform.TargetMachine) Dimensions(org.gradle.language.nativeplatform.internal.Dimensions) ToolChainSelector(org.gradle.language.nativeplatform.internal.toolchains.ToolChainSelector) MacOSSdkPlatformPathLocator(org.gradle.nativeplatform.toolchain.internal.xcode.MacOSSdkPlatformPathLocator) TaskContainer(org.gradle.api.tasks.TaskContainer) Names(org.gradle.language.nativeplatform.internal.Names) NativeToolChain(org.gradle.nativeplatform.toolchain.NativeToolChain) SwiftPlatform(org.gradle.language.swift.SwiftPlatform) SwiftXCTestBinary(org.gradle.nativeplatform.test.xctest.SwiftXCTestBinary) DefaultSwiftXCTestBinary(org.gradle.nativeplatform.test.xctest.internal.DefaultSwiftXCTestBinary) NativeTestingBasePlugin(org.gradle.nativeplatform.test.plugins.NativeTestingBasePlugin) Dimensions.useHostAsDefaultTargetMachine(org.gradle.language.nativeplatform.internal.Dimensions.useHostAsDefaultTargetMachine) Dimensions.tryToBuildOnHost(org.gradle.language.nativeplatform.internal.Dimensions.tryToBuildOnHost) Inject(javax.inject.Inject) LifecycleBasePlugin(org.gradle.language.base.plugins.LifecycleBasePlugin) Lists(com.google.common.collect.Lists) Sync(org.gradle.api.tasks.Sync) LinkMachOBundle(org.gradle.nativeplatform.tasks.LinkMachOBundle) DefaultSwiftPlatform(org.gradle.language.swift.internal.DefaultSwiftPlatform) NativeComponentFactory(org.gradle.language.internal.NativeComponentFactory) SwiftApplication(org.gradle.language.swift.SwiftApplication) SwiftComponent(org.gradle.language.swift.SwiftComponent) NativeToolChainInternal(org.gradle.nativeplatform.toolchain.internal.NativeToolChainInternal) SwiftCompile(org.gradle.language.swift.tasks.SwiftCompile) File(java.io.File) SetProperty(org.gradle.api.provider.SetProperty) ProviderFactory(org.gradle.api.provider.ProviderFactory) DefaultSwiftBinary(org.gradle.language.swift.internal.DefaultSwiftBinary) ObjectFactory(org.gradle.api.model.ObjectFactory) DefaultSwiftXCTestBundle(org.gradle.nativeplatform.test.xctest.internal.DefaultSwiftXCTestBundle) RegularFile(org.gradle.api.file.RegularFile) InstallXCTestBundle(org.gradle.nativeplatform.test.xctest.tasks.InstallXCTestBundle) Dependency(org.gradle.api.artifacts.Dependency) Plugin(org.gradle.api.Plugin) SwiftXCTestSuite(org.gradle.nativeplatform.test.xctest.SwiftXCTestSuite) DefaultSwiftXCTestExecutable(org.gradle.nativeplatform.test.xctest.internal.DefaultSwiftXCTestExecutable) RegularFile(org.gradle.api.file.RegularFile) ProjectInternal(org.gradle.api.internal.project.ProjectInternal) NativeToolChain(org.gradle.nativeplatform.toolchain.NativeToolChain) SwiftXCTestBundle(org.gradle.nativeplatform.test.xctest.SwiftXCTestBundle) DefaultSwiftXCTestBundle(org.gradle.nativeplatform.test.xctest.internal.DefaultSwiftXCTestBundle) Names(org.gradle.language.nativeplatform.internal.Names) InstallXCTestBundle(org.gradle.nativeplatform.test.xctest.tasks.InstallXCTestBundle) NativeToolChainInternal(org.gradle.nativeplatform.toolchain.internal.NativeToolChainInternal) ModelRegistry(org.gradle.model.internal.registry.ModelRegistry) SwiftCompile(org.gradle.language.swift.tasks.SwiftCompile) TaskContainer(org.gradle.api.tasks.TaskContainer) NativeToolChainRegistryInternal(org.gradle.nativeplatform.toolchain.internal.NativeToolChainRegistryInternal) PlatformToolProvider(org.gradle.nativeplatform.toolchain.internal.PlatformToolProvider) DefaultNativePlatform(org.gradle.nativeplatform.platform.internal.DefaultNativePlatform) LinkMachOBundle(org.gradle.nativeplatform.tasks.LinkMachOBundle) DefaultSwiftXCTestBundle(org.gradle.nativeplatform.test.xctest.internal.DefaultSwiftXCTestBundle) Sync(org.gradle.api.tasks.Sync) File(java.io.File) RegularFile(org.gradle.api.file.RegularFile)

Aggregations

Sync (org.gradle.api.tasks.Sync)11 File (java.io.File)8 Project (org.gradle.api.Project)6 HashMap (java.util.HashMap)4 GradleException (org.gradle.api.GradleException)4 Plugin (org.gradle.api.Plugin)4 Task (org.gradle.api.Task)4 TaskProvider (org.gradle.api.tasks.TaskProvider)4 ArrayList (java.util.ArrayList)3 List (java.util.List)3 Action (org.gradle.api.Action)3 IOException (java.io.IOException)2 Arrays (java.util.Arrays)2 Collections (java.util.Collections)2 Map (java.util.Map)2 Inject (javax.inject.Inject)2 Configuration (org.gradle.api.artifacts.Configuration)2 ObjectFactory (org.gradle.api.model.ObjectFactory)2 Provider (org.gradle.api.provider.Provider)2 Copy (org.gradle.api.tasks.Copy)2