Enable generation of Gradle's module metadata

Changes in Gradle 6.2 should address the problems described in
4f75ab5f.

Closes gh-19609
pull/20472/head
Andy Wilkinson 5 years ago
parent 19cc388861
commit 47a68650c9

@ -51,7 +51,6 @@ import org.gradle.api.publish.maven.MavenPomOrganization;
import org.gradle.api.publish.maven.MavenPomScm;
import org.gradle.api.publish.maven.MavenPublication;
import org.gradle.api.publish.maven.plugins.MavenPublishPlugin;
import org.gradle.api.publish.tasks.GenerateModuleMetadata;
import org.gradle.api.resources.TextResourceFactory;
import org.gradle.api.tasks.bundling.Jar;
import org.gradle.api.tasks.compile.JavaCompile;
@ -100,8 +99,6 @@ import org.springframework.util.FileCopyUtils;
* Maven Central's requirements.
* <li>If the {@link JavaPlugin Java plugin} has also been applied, creation of Javadoc
* and source jars is enabled.
* <li>Generation of Gradle module metadata is disabled as it is incompatible with our
* two-step publishing process.</li>
* </ul>
*
* <p/>
@ -229,7 +226,6 @@ public class ConventionsPlugin implements Plugin<Project> {
private void applyMavenPublishingConventions(Project project) {
project.getPlugins().withType(MavenPublishPlugin.class).all((mavenPublish) -> {
project.getTasks().withType(GenerateModuleMetadata.class).all((generate) -> generate.setEnabled(false));
PublishingExtension publishing = project.getExtensions().getByType(PublishingExtension.class);
if (project.hasProperty("deploymentRepository")) {
publishing.getRepositories().maven((mavenRepository) -> {

Loading…
Cancel
Save