Search in sources :

Example 1 with ShadowJar

use of com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar in project micronaut-gradle-plugin by micronaut-projects.

the class AotShadowSupport method registerShadowJar.

static void registerShadowJar(Project project, ArchiveOperations archiveOperations, TaskContainer tasks, TaskProvider<Jar> optimizedJar) {
    project.afterEvaluate(unused -> {
        JavaApplication javaApplication = project.getExtensions().findByType(JavaApplication.class);
        TaskProvider<ShadowJar> shadowProvider = tasks.register(optimizedJar.getName() + "All", ShadowJar.class, shadow -> {
            shadow.setGroup(SHADOW_GROUP);
            shadow.setDescription("Creates a fat jar including the Micronaut AOT optimizations");
            shadow.getArchiveClassifier().convention("all-optimized");
            Jar mainJar = tasks.named("jar", Jar.class).get();
            shadow.getManifest().inheritFrom(mainJar.getManifest());
            if (javaApplication != null) {
                // This is the reason why we use an afterEvalute:
                // The shadow plugin apparently does something with attributes,
                // breaking support for providers
                shadow.getManifest().getAttributes().put("Main-Class", javaApplication.getMainClass().get());
            }
            shadow.from(optimizedJar.map(jar -> archiveOperations.zipTree(jar.getArchiveFile().get())));
            shadow.getConfigurations().add(project.getConfigurations().findByName("runtimeClasspath"));
            shadow.getExcludes().addAll(tasks.named(ShadowJavaPlugin.SHADOW_JAR_TASK_NAME, ShadowJar.class).get().getExcludes());
        });
        tasks.named("assemble").configure(assemble -> assemble.dependsOn(shadowProvider));
    });
}
Also used : ShadowJar(com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar) Jar(org.gradle.api.tasks.bundling.Jar) TaskContainer(org.gradle.api.tasks.TaskContainer) Project(org.gradle.api.Project) TaskProvider(org.gradle.api.tasks.TaskProvider) ArchiveOperations(org.gradle.api.file.ArchiveOperations) ShadowJavaPlugin(com.github.jengelman.gradle.plugins.shadow.ShadowJavaPlugin) JavaApplication(org.gradle.api.plugins.JavaApplication) SHADOW_GROUP(com.github.jengelman.gradle.plugins.shadow.ShadowJavaPlugin.SHADOW_GROUP) ShadowJar(com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar) JavaApplication(org.gradle.api.plugins.JavaApplication) ShadowJar(com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar) Jar(org.gradle.api.tasks.bundling.Jar)

Example 2 with ShadowJar

use of com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar in project checkstyle-addons by checkstyle-addons.

the class TaskCreator method setupArtifactTasks.

public void setupArtifactTasks(@Nonnull final DependencyConfigs pDepConfigs) {
    final TaskContainer tasks = project.getTasks();
    for (final DependencyConfig depConfig : pDepConfigs.getAll().values()) {
        final String pubSuffix = depConfig.getName();
        // 'generatePomProperties' task
        final String pomPropsTaskName = TaskNames.generatePomProperties.getName(depConfig);
        final TaskProvider<GeneratePomPropsTask> pomPropsTaskTaskProvider = tasks.register(pomPropsTaskName, GeneratePomPropsTask.class);
        pomPropsTaskTaskProvider.configure(pomPropsTask -> {
            pomPropsTask.getAppendix().set(depConfig.isDefaultConfig() ? null : pubSuffix);
            pomPropsTask.updateDescription();
        });
        // 'jar' task
        final String jarTaskName = TaskNames.jar.getName(depConfig);
        final TaskProvider<Jar> jarTaskProvider = tasks.register(jarTaskName, Jar.class);
        jarTaskProvider.configure(new JarConfigAction(depConfig));
        // 'fatjar' task
        final String fatjarTaskName = TaskNames.fatJar.getName(depConfig);
        final TaskProvider<ShadowJar> shadowJarTaskProvider = tasks.register(fatjarTaskName, ShadowJar.class);
        shadowJarTaskProvider.configure(new FatJarConfigAction(depConfig));
        // 'jarSources' task
        final String jarSourcesTaskName = TaskNames.jarSources.getName(depConfig);
        final TaskProvider<Jar> jarSourcesTaskProvider = tasks.register(jarSourcesTaskName, Jar.class);
        jarSourcesTaskProvider.configure(new JarSourcesConfigAction(depConfig));
        // 'jarJavadoc' task
        final String jarJavadocTaskName = TaskNames.jarJavadoc.getName(depConfig);
        final TaskProvider<Jar> jarJavadocTaskProvider = tasks.register(jarJavadocTaskName, Jar.class);
        jarJavadocTaskProvider.configure(new JarJavadocConfigAction(depConfig));
        // 'jarEclipse' task
        final String eclipseTaskName = TaskNames.jarEclipse.getName(depConfig);
        final TaskProvider<Jar> jarEclipseTaskProvider = tasks.register(eclipseTaskName, Jar.class);
        jarEclipseTaskProvider.configure(new JarEclipseConfigAction(depConfig));
        // 'jarSonarqube' task (with 'jarSonarqubeRelocate' task)
        TaskProvider<ShadowJar> jarSqTaskProvider = null;
        if (depConfig.isSonarQubeSupported()) {
            final String sqTaskName = TaskNames.jarSonarqube.getName(depConfig);
            final String relocateTaskName = TaskNames.jarSonarqubeRelocate.getName(depConfig);
            final TaskProvider<ConfigureShadowRelocation> relocationTaskProvider = tasks.register(relocateTaskName, ConfigureShadowRelocation.class);
            relocationTaskProvider.configure(relocTask -> {
                relocTask.setTarget((ShadowJar) tasks.getByName(sqTaskName));
                relocTask.setPrefix("com.thomasjensen.checkstyle.addons.shadow");
            });
            jarSqTaskProvider = tasks.register(sqTaskName, ShadowJar.class);
            jarSqTaskProvider.configure(new JarSonarqubeConfigAction(depConfig));
            jarSqTaskProvider.configure(t -> t.dependsOn(relocationTaskProvider));
        }
        final TaskProvider<ShadowJar> jarSqTaskProviderFinal = jarSqTaskProvider;
        // 'assemble' task for the dependency configuration
        TaskProvider<Task> assembleTaskProvider = null;
        if (depConfig.isDefaultConfig()) {
            assembleTaskProvider = tasks.named(BasePlugin.ASSEMBLE_TASK_NAME);
        } else {
            assembleTaskProvider = tasks.register(TaskNames.assemble.getName(depConfig));
            assembleTaskProvider.configure(assembleTask -> assembleTask.setDescription("Assembles the artifacts belonging to dependency configuration '" + depConfig.getName() + "'"));
            final TaskProvider<Task> assembleTaskProviderFinal = assembleTaskProvider;
            final TaskProvider<Task> buildTaskProvider = tasks.named(JavaBasePlugin.BUILD_TASK_NAME);
            buildTaskProvider.configure(buildTask -> buildTask.dependsOn(assembleTaskProviderFinal));
        }
        assembleTaskProvider.configure(assembleTask -> {
            assembleTask.setGroup(ARTIFACTS_GROUP_NAME);
            assembleTask.dependsOn(jarTaskProvider);
            assembleTask.dependsOn(shadowJarTaskProvider);
            assembleTask.dependsOn(jarSourcesTaskProvider);
            assembleTask.dependsOn(jarJavadocTaskProvider);
            assembleTask.dependsOn(jarEclipseTaskProvider);
            if (jarSqTaskProviderFinal != null) {
                assembleTask.dependsOn(jarSqTaskProviderFinal);
            }
        });
    }
    // disable standard 'jar' task
    tasks.named(JavaPlugin.JAR_TASK_NAME).configure(t -> t.setEnabled(false));
}
Also used : ConfigureShadowRelocation(com.github.jengelman.gradle.plugins.shadow.tasks.ConfigureShadowRelocation) GeneratePomPropsTask(com.thomasjensen.checkstyle.addons.build.tasks.GeneratePomPropsTask) Task(org.gradle.api.Task) JarEclipseConfigAction(com.thomasjensen.checkstyle.addons.build.tasks.JarEclipseConfigAction) ShadowJar(com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar) JarSonarqubeConfigAction(com.thomasjensen.checkstyle.addons.build.tasks.JarSonarqubeConfigAction) FatJarConfigAction(com.thomasjensen.checkstyle.addons.build.tasks.FatJarConfigAction) JarConfigAction(com.thomasjensen.checkstyle.addons.build.tasks.JarConfigAction) JarJavadocConfigAction(com.thomasjensen.checkstyle.addons.build.tasks.JarJavadocConfigAction) FatJarConfigAction(com.thomasjensen.checkstyle.addons.build.tasks.FatJarConfigAction) JarSourcesConfigAction(com.thomasjensen.checkstyle.addons.build.tasks.JarSourcesConfigAction) TaskContainer(org.gradle.api.tasks.TaskContainer) ShadowJar(com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar) Jar(org.gradle.api.tasks.bundling.Jar) GeneratePomPropsTask(com.thomasjensen.checkstyle.addons.build.tasks.GeneratePomPropsTask)

Example 3 with ShadowJar

use of com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar in project OpenSearch by opensearch-project.

the class OpenSearchJavaPlugin method configureJars.

/**
 * Adds additional manifest info to jars
 */
static void configureJars(Project project) {
    project.getTasks().withType(Jar.class).configureEach(jarTask -> {
        // we put all our distributable files under distributions
        jarTask.getDestinationDirectory().set(new File(project.getBuildDir(), "distributions"));
        // fixup the jar manifest
        // Explicitly using an Action interface as java lambdas
        // are not supported by Gradle up-to-date checks
        jarTask.doFirst(new Action<Task>() {

            @Override
            public void execute(Task task) {
                // this doFirst is added before the info plugin, therefore it will run
                // after the doFirst added by the info plugin, and we can override attributes
                jarTask.getManifest().attributes(new HashMap<String, Object>() {

                    {
                        put("Build-Date", BuildParams.getBuildDate());
                        put("Build-Java-Version", BuildParams.getGradleJavaVersion());
                    }
                });
            }
        });
    });
    project.getPluginManager().withPlugin("com.github.johnrengelman.shadow", p -> {
        project.getTasks().withType(ShadowJar.class).configureEach(shadowJar -> {
            /*
                 * Replace the default "-all" classifier with null
                 * which will leave the classifier off of the file name.
                 */
            shadowJar.getArchiveClassifier().set((String) null);
            /*
                 * Not all cases need service files merged but it is
                 * better to be safe
                 */
            shadowJar.mergeServiceFiles();
        });
        // Add "original" classifier to the non-shadowed JAR to distinguish it from the shadow JAR
        project.getTasks().named(JavaPlugin.JAR_TASK_NAME, Jar.class).configure(jar -> jar.getArchiveClassifier().set("original"));
        // Make sure we assemble the shadow jar
        project.getTasks().named(BasePlugin.ASSEMBLE_TASK_NAME).configure(task -> task.dependsOn("shadowJar"));
    });
}
Also used : Task(org.gradle.api.Task) HashMap(java.util.HashMap) ShadowJar(com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar) ShadowJar(com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar) Jar(org.gradle.api.tasks.bundling.Jar) File(java.io.File)

Example 4 with ShadowJar

use of com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar in project checkstyle-addons by checkstyle-addons.

the class FatJarConfigAction method configureTaskFor.

@Override
protected void configureTaskFor(@Nonnull ShadowJar pFatJarTask, @Nullable DependencyConfig pDepConfig) {
    Objects.requireNonNull(pDepConfig, "required dependency config not present");
    pFatJarTask.setGroup(TaskCreator.ARTIFACTS_GROUP_NAME);
    pFatJarTask.getArchiveClassifier().set("all");
    // set appendix for archive name
    final String appendix = pDepConfig.getName();
    if (!pDepConfig.isDefaultConfig()) {
        pFatJarTask.getArchiveAppendix().set(appendix);
    }
    // dependency on the corresponding (thin) Jar task
    final Jar thinJarTask = buildUtil.getTask(TaskNames.jar, Jar.class, pDepConfig);
    pFatJarTask.dependsOn(thinJarTask);
    pFatJarTask.setDescription("Create a combined JAR of project and runtime dependencies of '" + SourceSet.MAIN_SOURCE_SET_NAME + "' for dependency configuration '" + pDepConfig.getName() + "'");
    buildUtil.inheritManifest(pFatJarTask, pDepConfig);
    pFatJarTask.from(thinJarTask.getArchiveFile());
    Configuration cfg = new ClasspathBuilder(project).buildMainRuntimeConfiguration(pDepConfig);
    pFatJarTask.setConfigurations(Collections.singletonList(cfg));
    pFatJarTask.exclude("META-INF/INDEX.LIST", "META-INF/*.SF", "META-INF/*.DSA", "META-INF/*.RSA", "META-INF/maven/**/*", "pom.xml");
    final Set<String> deps = getNonCheckstyleDeps(cfg);
    if (deps.size() > 0) {
        // append all licenses found in dependent Jars into one
        pFatJarTask.append("META-INF/LICENSE");
        pFatJarTask.dependencies((final DependencyFilter pDependencyFilter) -> {
            for (String dep : deps) {
                pDependencyFilter.include(pDependencyFilter.dependency(dep));
            }
        });
    }
}
Also used : Configuration(org.gradle.api.artifacts.Configuration) ClasspathBuilder(com.thomasjensen.checkstyle.addons.build.ClasspathBuilder) ShadowJar(com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar) Jar(org.gradle.api.tasks.bundling.Jar) DependencyFilter(com.github.jengelman.gradle.plugins.shadow.internal.DependencyFilter)

Example 5 with ShadowJar

use of com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar in project ehcache3 by ehcache.

the class PackagePlugin method createPackage.

private void createPackage(Project project, Optional<VariantPlugin.Variant> variant) {
    String name = variant.map(VariantPlugin.Variant::getName).orElse(null);
    ServiceRegistry projectServices = ((ProjectInternal) project).getServices();
    JvmPluginServices jvmPluginServices = projectServices.get(JvmPluginServices.class);
    ConfigurationBucketSet packageBuckets = ConfigurationBucketSet.bucketsFor(project, name, CONTENTS_KIND);
    Configuration contentsCompileClasspath = jvmPluginServices.createResolvableConfiguration(lower(camel(name, CONTENTS_KIND, COMPILE_CLASSPATH_CONFIGURATION_NAME)), builder -> builder.extendsFrom(packageBuckets.bucket(CONTENTS_KIND)).requiresJavaLibrariesAPI());
    Configuration contentsRuntimeClasspath = jvmPluginServices.createResolvableConfiguration(lower(camel(name, CONTENTS_KIND, RUNTIME_CLASSPATH_CONFIGURATION_NAME)), builder -> builder.extendsFrom(packageBuckets.bucket(CONTENTS_KIND)).requiresJavaLibrariesRuntime());
    Configuration contentsSourcesFiles = jvmPluginServices.createResolvableConfiguration(lower(camel(name, CONTENTS_KIND, "sourcesFiles")), builder -> builder.extendsFrom(packageBuckets.bucket(CONTENTS_KIND)).requiresAttributes(refiner -> refiner.documentation(SOURCES)));
    TaskProvider<ShadowJar> shadowJar = project.getTasks().register(lower(camel(name, "jar")), ShadowJar.class, shadow -> {
        shadow.setGroup(BasePlugin.BUILD_GROUP);
        shadow.getArchiveClassifier().set(name);
        shadow.setConfigurations(Collections.singletonList(contentsRuntimeClasspath));
        shadow.relocate("org.terracotta.statistics.", "org.ehcache.shadow.org.terracotta.statistics.");
        shadow.relocate("org.terracotta.offheapstore.", "org.ehcache.shadow.org.terracotta.offheapstore.");
        shadow.relocate("org.terracotta.context.", "org.ehcache.shadow.org.terracotta.context.");
        shadow.relocate("org.terracotta.utilities.", "org.ehcache.shadow.org.terracotta.utilities.");
        shadow.mergeServiceFiles();
        shadow.exclude("META-INF/MANIFEST.MF", "LICENSE", "NOTICE");
        // LICENSE is included in root gradle build
        shadow.from(new File(project.getRootDir(), "NOTICE"));
        shadow.setDuplicatesStrategy(DuplicatesStrategy.EXCLUDE);
    });
    Configuration apiElements = jvmPluginServices.createOutgoingElements(lower(camel(name, API_ELEMENTS_CONFIGURATION_NAME)), builder -> builder.extendsFrom(packageBuckets.api()).extendsFrom(packageBuckets.compileOnlyApi()).published().providesApi().artifact(shadowJar));
    configureDefaultTargetPlatform(apiElements, 8);
    Configuration compileClasspath = jvmPluginServices.createResolvableConfiguration(lower(camel(name, COMPILE_CLASSPATH_CONFIGURATION_NAME)), builder -> builder.extendsFrom(packageBuckets.implementation()).extendsFrom(packageBuckets.compileOnly()).requiresJavaLibrariesRuntime());
    Configuration runtimeElements = jvmPluginServices.createOutgoingElements(lower(camel(name, RUNTIME_ELEMENTS_CONFIGURATION_NAME)), builder -> builder.extendsFrom(packageBuckets.implementation()).extendsFrom(packageBuckets.runtimeOnly()).published().providesRuntime().artifact(shadowJar));
    configureDefaultTargetPlatform(runtimeElements, 8);
    Configuration runtimeClasspath = jvmPluginServices.createResolvableConfiguration(lower(camel(name, RUNTIME_CLASSPATH_CONFIGURATION_NAME)), builder -> builder.extendsFrom(packageBuckets.implementation()).extendsFrom(packageBuckets.runtimeOnly()).requiresJavaLibrariesRuntime());
    Provider<FileCollection> sourcesTree = project.provider(() -> contentsSourcesFiles.getResolvedConfiguration().getLenientConfiguration().getAllModuleDependencies().stream().flatMap(d -> d.getModuleArtifacts().stream()).map(artifact -> {
        try {
            return Optional.of(artifact.getFile());
        } catch (ArtifactResolveException e) {
            return Optional.<File>empty();
        }
    }).filter(Optional::isPresent).map(Optional::get).distinct().map(file -> {
        if (file.isFile()) {
            return project.zipTree(file);
        } else {
            return project.fileTree(file);
        }
    }).reduce(FileTree::plus).orElse(project.files().getAsFileTree()));
    TaskProvider<Sync> sources = project.getTasks().register(lower(camel(name, "sources")), Sync.class, sync -> {
        sync.dependsOn(contentsSourcesFiles);
        sync.from(sourcesTree, spec -> spec.exclude("META-INF/**", "LICENSE", "NOTICE"));
        sync.into(project.getLayout().getBuildDirectory().dir(lower(camel(name, "sources"))));
    });
    TaskProvider<Jar> sourcesJar = project.getTasks().register(lower(camel(name, "sourcesJar")), Jar.class, jar -> {
        jar.setGroup(BasePlugin.BUILD_GROUP);
        jar.from(sources);
        jar.from(shadowJar, spec -> spec.include("META-INF/**", "LICENSE", "NOTICE"));
        jar.getArchiveClassifier().set(kebab(name, "sources"));
    });
    Configuration sourcesElements = jvmPluginServices.createOutgoingElements(lower(camel(name, SOURCES_ELEMENTS_CONFIGURATION_NAME)), builder -> builder.published().artifact(sourcesJar).providesAttributes(attributes -> attributes.documentation(SOURCES).asJar()));
    TaskProvider<Javadoc> javadoc = project.getTasks().register(lower(camel(name, "javadoc")), Javadoc.class, task -> {
        task.setGroup(JavaBasePlugin.DOCUMENTATION_GROUP);
        task.setTitle(project.getName() + " " + project.getVersion() + " API");
        task.source(sources);
        task.include("**/*.java");
        task.setClasspath(contentsCompileClasspath.plus(compileClasspath));
        task.setDestinationDir(new File(project.getBuildDir(), "docs/" + lower(camel(name, "javadoc"))));
    });
    TaskProvider<Jar> javadocJar = project.getTasks().register(lower(camel(name, "javadocJar")), Jar.class, jar -> {
        jar.setGroup(BasePlugin.BUILD_GROUP);
        jar.from(javadoc);
        jar.getArchiveClassifier().set(kebab(name, "javadoc"));
    });
    Configuration javadocElements = jvmPluginServices.createOutgoingElements(lower(camel(name, JAVADOC_ELEMENTS_CONFIGURATION_NAME)), builder -> builder.published().artifact(javadocJar).providesAttributes(attributes -> attributes.documentation(JAVADOC).asJar()));
    shadowJar.configure(shadow -> {
        OsgiManifestJarExtension osgiExtension = new OsgiManifestJarExtension(shadow);
        osgiExtension.getClasspath().from(runtimeClasspath);
        osgiExtension.getSources().from(sources);
        BndConvention.bundleDefaults(project).execute(osgiExtension.getInstructions());
    });
    project.getComponents().named("java", AdhocComponentWithVariants.class, java -> {
        java.addVariantsFromConfiguration(apiElements, variantDetails -> {
            variantDetails.mapToMavenScope("compile");
            variant.ifPresent(v -> variantDetails.mapToOptional());
        });
        java.addVariantsFromConfiguration(runtimeElements, variantDetails -> {
            variantDetails.mapToMavenScope("runtime");
            variant.ifPresent(v -> variantDetails.mapToOptional());
        });
        java.addVariantsFromConfiguration(sourcesElements, variantDetails -> {
        });
        java.addVariantsFromConfiguration(javadocElements, variantDetails -> {
        });
    });
    if (variant.isPresent()) {
        VariantPlugin.Variant v = variant.get();
        ConfigurationBucketSet commonBuckets = ConfigurationBucketSet.bucketsFor(project, COMMON_KIND, CONTENTS_KIND);
        packageBuckets.extendFrom(commonBuckets);
        v.getConfigTraits().configureEach(trait -> packageBuckets.extendFrom(ConfigurationBucketSet.bucketsFor(project, camel(trait, "trait"))));
        v.getCapabilities().configureEach(capability -> {
            apiElements.getOutgoing().capability(capability);
            runtimeElements.getOutgoing().capability(capability);
            sourcesElements.getOutgoing().capability(capability);
            javadocElements.getOutgoing().capability(capability);
        });
    } else {
        project.getPlugins().withType(VariantPlugin.class).configureEach(variantPlugin -> {
            project.getExtensions().configure(VariantPlugin.VariantExtension.class, variants -> {
                VariantPlugin.Variant v = variants.getDefaultVariant();
                ConfigurationBucketSet commonBuckets = ConfigurationBucketSet.bucketsFor(project, COMMON_KIND, CONTENTS_KIND);
                packageBuckets.extendFrom(commonBuckets);
                v.getConfigTraits().configureEach(trait -> packageBuckets.extendFrom(ConfigurationBucketSet.bucketsFor(project, camel(trait, "trait"))));
                v.getCapabilities().configureEach(capability -> {
                    apiElements.getOutgoing().capability(capability);
                    runtimeElements.getOutgoing().capability(capability);
                    sourcesElements.getOutgoing().capability(capability);
                    javadocElements.getOutgoing().capability(capability);
                });
            });
        });
    }
    project.getTasks().named(LifecycleBasePlugin.ASSEMBLE_TASK_NAME).configure(task -> {
        task.dependsOn(shadowJar);
        task.dependsOn(javadocJar);
        task.dependsOn(sourcesJar);
    });
}
Also used : PluginUtils.camel(org.ehcache.build.util.PluginUtils.camel) MavenPublishPlugin(org.gradle.api.publish.maven.plugins.MavenPublishPlugin) SOURCES(org.gradle.api.attributes.DocsType.SOURCES) AdhocComponentWithVariants(org.gradle.api.component.AdhocComponentWithVariants) BndConvention(org.ehcache.build.conventions.BndConvention) Provider(org.gradle.api.provider.Provider) PublishingExtension(org.gradle.api.publish.PublishingExtension) Javadoc(org.gradle.api.tasks.javadoc.Javadoc) JavaBasePlugin(org.gradle.api.plugins.JavaBasePlugin) FileTree(org.gradle.api.file.FileTree) TaskProvider(org.gradle.api.tasks.TaskProvider) ProjectInternal(org.gradle.api.internal.project.ProjectInternal) COMMON_KIND(org.ehcache.build.plugins.VariantPlugin.COMMON_KIND) JavaBaseConvention(org.ehcache.build.conventions.JavaBaseConvention) DuplicatesStrategy(org.gradle.api.file.DuplicatesStrategy) OsgiManifestJarExtension(org.ehcache.build.util.OsgiManifestJarExtension) Zip(org.gradle.api.tasks.bundling.Zip) ShadowJar(com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar) RUNTIME_CLASSPATH_CONFIGURATION_NAME(org.gradle.api.plugins.JavaPlugin.RUNTIME_CLASSPATH_CONFIGURATION_NAME) Jvm(org.gradle.internal.jvm.Jvm) Project(org.gradle.api.Project) API_ELEMENTS_CONFIGURATION_NAME(org.gradle.api.plugins.JavaPlugin.API_ELEMENTS_CONFIGURATION_NAME) Optional(java.util.Optional) JvmPluginServices(org.gradle.api.plugins.jvm.internal.JvmPluginServices) ServiceRegistry(org.gradle.internal.service.ServiceRegistry) PluginUtils.kebab(org.ehcache.build.util.PluginUtils.kebab) RUNTIME_ELEMENTS_CONFIGURATION_NAME(org.gradle.api.plugins.JavaPlugin.RUNTIME_ELEMENTS_CONFIGURATION_NAME) PluginUtils.lower(org.ehcache.build.util.PluginUtils.lower) BasePlugin(org.gradle.api.plugins.BasePlugin) MavenPublication(org.gradle.api.publish.maven.MavenPublication) FileCollection(org.gradle.api.file.FileCollection) Configuration(org.gradle.api.artifacts.Configuration) LifecycleBasePlugin(org.gradle.language.base.plugins.LifecycleBasePlugin) Sync(org.gradle.api.tasks.Sync) BaseConvention(org.ehcache.build.conventions.BaseConvention) COMPILE_CLASSPATH_CONFIGURATION_NAME(org.gradle.api.plugins.JavaPlugin.COMPILE_CLASSPATH_CONFIGURATION_NAME) ConfigurationBucketSet(org.ehcache.build.util.ConfigurationBucketSet) Jar(org.gradle.api.tasks.bundling.Jar) JAVADOC(org.gradle.api.attributes.DocsType.JAVADOC) USER_MANUAL(org.gradle.api.attributes.DocsType.USER_MANUAL) Integer.parseInt(java.lang.Integer.parseInt) JAVADOC_ELEMENTS_CONFIGURATION_NAME(org.gradle.api.plugins.JavaPlugin.JAVADOC_ELEMENTS_CONFIGURATION_NAME) File(java.io.File) SoftwareComponentFactory(org.gradle.api.component.SoftwareComponentFactory) SOURCES_ELEMENTS_CONFIGURATION_NAME(org.gradle.api.plugins.JavaPlugin.SOURCES_ELEMENTS_CONFIGURATION_NAME) JavaEcosystemSupport.configureDefaultTargetPlatform(org.gradle.api.internal.artifacts.JavaEcosystemSupport.configureDefaultTargetPlatform) ArtifactResolveException(org.gradle.internal.resolve.ArtifactResolveException) Collections(java.util.Collections) Plugin(org.gradle.api.Plugin) OsgiManifestJarExtension(org.ehcache.build.util.OsgiManifestJarExtension) Configuration(org.gradle.api.artifacts.Configuration) ArtifactResolveException(org.gradle.internal.resolve.ArtifactResolveException) Optional(java.util.Optional) ShadowJar(com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar) ProjectInternal(org.gradle.api.internal.project.ProjectInternal) Javadoc(org.gradle.api.tasks.javadoc.Javadoc) FileCollection(org.gradle.api.file.FileCollection) JvmPluginServices(org.gradle.api.plugins.jvm.internal.JvmPluginServices) FileTree(org.gradle.api.file.FileTree) ShadowJar(com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar) Jar(org.gradle.api.tasks.bundling.Jar) ServiceRegistry(org.gradle.internal.service.ServiceRegistry) Sync(org.gradle.api.tasks.Sync) File(java.io.File) ConfigurationBucketSet(org.ehcache.build.util.ConfigurationBucketSet)

Aggregations

ShadowJar (com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar)5 Jar (org.gradle.api.tasks.bundling.Jar)5 File (java.io.File)2 Project (org.gradle.api.Project)2 Task (org.gradle.api.Task)2 Configuration (org.gradle.api.artifacts.Configuration)2 TaskContainer (org.gradle.api.tasks.TaskContainer)2 ShadowJavaPlugin (com.github.jengelman.gradle.plugins.shadow.ShadowJavaPlugin)1 SHADOW_GROUP (com.github.jengelman.gradle.plugins.shadow.ShadowJavaPlugin.SHADOW_GROUP)1 DependencyFilter (com.github.jengelman.gradle.plugins.shadow.internal.DependencyFilter)1 ConfigureShadowRelocation (com.github.jengelman.gradle.plugins.shadow.tasks.ConfigureShadowRelocation)1 ClasspathBuilder (com.thomasjensen.checkstyle.addons.build.ClasspathBuilder)1 FatJarConfigAction (com.thomasjensen.checkstyle.addons.build.tasks.FatJarConfigAction)1 GeneratePomPropsTask (com.thomasjensen.checkstyle.addons.build.tasks.GeneratePomPropsTask)1 JarConfigAction (com.thomasjensen.checkstyle.addons.build.tasks.JarConfigAction)1 JarEclipseConfigAction (com.thomasjensen.checkstyle.addons.build.tasks.JarEclipseConfigAction)1 JarJavadocConfigAction (com.thomasjensen.checkstyle.addons.build.tasks.JarJavadocConfigAction)1 JarSonarqubeConfigAction (com.thomasjensen.checkstyle.addons.build.tasks.JarSonarqubeConfigAction)1 JarSourcesConfigAction (com.thomasjensen.checkstyle.addons.build.tasks.JarSourcesConfigAction)1 Integer.parseInt (java.lang.Integer.parseInt)1