From c0a5245a3ea9b80bd002eba9f06d74b4fa2ad6df Mon Sep 17 00:00:00 2001 From: Robert Smith <58187843+robert-smith-911@users.noreply.github.com> Date: Mon, 15 Feb 2021 18:40:25 -0500 Subject: [PATCH 1/2] Encourage use of maven-publish plugin in Gradle docs See gh-25299 --- .../src/docs/asciidoc/publishing.adoc | 40 +++++++++---------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/docs/asciidoc/publishing.adoc b/spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/docs/asciidoc/publishing.adoc index 5bb1e97017d..8173588d305 100644 --- a/spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/docs/asciidoc/publishing.adoc +++ b/spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/docs/asciidoc/publishing.adoc @@ -3,26 +3,6 @@ -[[publishing-your-application-maven]] -=== Publishing with the Maven Plugin -When the {maven-plugin}[`maven` plugin] is applied, an `Upload` task for the `bootArchives` configuration named `uploadBootArchives` is automatically created. -By default, the `bootArchives` configuration contains the archive produced by the `bootJar` or `bootWar` task. -The `uploadBootArchives` task can be configured to publish the archive to a Maven repository: - -[source,groovy,indent=0,subs="verbatim,attributes",role="primary"] -.Groovy ----- -include::../gradle/publishing/maven.gradle[tags=upload] ----- - -[source,kotlin,indent=0,subs="verbatim,attributes",role="secondary"] -.Kotlin ----- -include::../gradle/publishing/maven.gradle.kts[tags=upload] ----- - - - [[publishing-your-application-maven-publish]] === Publishing with the Maven-publish Plugin To publish your Spring Boot jar or war, add it to the publication using the `artifact` method on `MavenPublication`. @@ -43,6 +23,26 @@ include::../gradle/publishing/maven-publish.gradle.kts[tags=publishing] +[[publishing-your-application-maven]] +=== Publishing with the Maven Plugin +When the {maven-plugin}[`maven` plugin] is applied, an `Upload` task for the `bootArchives` configuration named `uploadBootArchives` is automatically created. +By default, the `bootArchives` configuration contains the archive produced by the `bootJar` or `bootWar` task. +The `uploadBootArchives` task can be configured to publish the archive to a Maven repository: + +[source,groovy,indent=0,subs="verbatim,attributes",role="primary"] +.Groovy +---- +include::../gradle/publishing/maven.gradle[tags=upload] +---- + +[source,kotlin,indent=0,subs="verbatim,attributes",role="secondary"] +.Kotlin +---- +include::../gradle/publishing/maven.gradle.kts[tags=upload] +---- + +WARNING: The maven plugin has been deprecated in Gradle 6.0 and is scheduled to be removed in Gradle 7.0. Please use the maven-publish plugin instead. + [[publishing-your-application-distribution]] === Distributing with the Application Plugin When the {application-plugin}[`application` plugin] is applied a distribution named `boot` is created. From a2adb877ee92bbca33c38d6703e46e4ce6ef39e7 Mon Sep 17 00:00:00 2001 From: Andy Wilkinson Date: Tue, 16 Feb 2021 11:22:47 +0000 Subject: [PATCH 2/2] Polish "Encourage use of maven-publish plugin in Gradle docs" See gh-25299 --- .../src/docs/asciidoc/publishing.adoc | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/docs/asciidoc/publishing.adoc b/spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/docs/asciidoc/publishing.adoc index 8173588d305..328b82fdf18 100644 --- a/spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/docs/asciidoc/publishing.adoc +++ b/spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/docs/asciidoc/publishing.adoc @@ -25,6 +25,9 @@ include::../gradle/publishing/maven-publish.gradle.kts[tags=publishing] [[publishing-your-application-maven]] === Publishing with the Maven Plugin +WARNING: The `maven` plugin has been deprecated in Gradle 6 and has been removed in Gradle 7. +Please use the `maven-publish` plugin instead. + When the {maven-plugin}[`maven` plugin] is applied, an `Upload` task for the `bootArchives` configuration named `uploadBootArchives` is automatically created. By default, the `bootArchives` configuration contains the archive produced by the `bootJar` or `bootWar` task. The `uploadBootArchives` task can be configured to publish the archive to a Maven repository: @@ -41,7 +44,7 @@ include::../gradle/publishing/maven.gradle[tags=upload] include::../gradle/publishing/maven.gradle.kts[tags=upload] ---- -WARNING: The maven plugin has been deprecated in Gradle 6.0 and is scheduled to be removed in Gradle 7.0. Please use the maven-publish plugin instead. + [[publishing-your-application-distribution]] === Distributing with the Application Plugin