Skip to content

Commit 08c67cc

Browse files
izeyephilwebb
authored andcommitted
Replace deprecated Project.task()
See gh-45009 Signed-off-by: Johnny Lim <[email protected]>
1 parent ce64f36 commit 08c67cc

File tree

41 files changed

+92
-92
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+92
-92
lines changed

spring-boot-project/spring-boot-devtools/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ dependencies {
8383
testRuntimeOnly("io.r2dbc:r2dbc-h2")
8484
}
8585

86-
task syncIntTestDependencies(type: Sync) {
86+
tasks.register("syncIntTestDependencies", Sync) {
8787
destinationDir = file(layout.buildDirectory.dir("dependencies"))
8888
from {
8989
configurations.intTestDependencies

spring-boot-project/spring-boot-docs/build.gradle

+10-10
Original file line numberDiff line numberDiff line change
@@ -227,38 +227,38 @@ task aggregatedJavadoc(type: Javadoc) {
227227
}
228228
}
229229

230-
task documentTestSlices(type: org.springframework.boot.build.test.autoconfigure.DocumentTestSlices) {
230+
tasks.register("documentTestSlices", org.springframework.boot.build.test.autoconfigure.DocumentTestSlices) {
231231
testSlices = configurations.testSlices
232232
outputFile = layout.buildDirectory.file("generated/docs/test-auto-configuration/documented-slices.adoc")
233233
}
234234

235-
task documentStarters(type: org.springframework.boot.build.starters.DocumentStarters) {
235+
tasks.register("documentStarters", org.springframework.boot.build.starters.DocumentStarters) {
236236
outputDir = layout.buildDirectory.dir("generated/docs/using/starters/")
237237
}
238238

239-
task documentAutoConfigurationClasses(type: org.springframework.boot.build.autoconfigure.DocumentAutoConfigurationClasses) {
239+
tasks.register("documentAutoConfigurationClasses", org.springframework.boot.build.autoconfigure.DocumentAutoConfigurationClasses) {
240240
autoConfiguration = configurations.autoConfiguration
241241
outputDir = layout.buildDirectory.dir("generated/docs/auto-configuration-classes/documented-auto-configuration-classes/")
242242
}
243243

244-
task documentDependencyVersionCoordinates(type: org.springframework.boot.build.docs.DocumentManagedDependencies) {
244+
tasks.register("documentDependencyVersionCoordinates", org.springframework.boot.build.docs.DocumentManagedDependencies) {
245245
outputFile = layout.buildDirectory.file("generated/docs/dependency-versions/documented-coordinates.adoc")
246246
resolvedBoms = configurations.resolvedBom
247247
}
248248

249-
task documentDependencyVersionProperties(type: org.springframework.boot.build.docs.DocumentVersionProperties) {
249+
tasks.register("documentDependencyVersionProperties", org.springframework.boot.build.docs.DocumentVersionProperties) {
250250
outputFile = layout.buildDirectory.file("generated/docs/dependency-versions/documented-properties.adoc")
251251
resolvedBoms = configurations.resolvedBom
252252
}
253253

254-
task documentConfigurationProperties(type: org.springframework.boot.build.context.properties.DocumentConfigurationProperties) {
254+
tasks.register("documentConfigurationProperties", org.springframework.boot.build.context.properties.DocumentConfigurationProperties) {
255255
configurationPropertyMetadata = configurations.configurationProperties
256256
outputDir = layout.buildDirectory.dir("generated/docs/application-properties")
257257
}
258258

259-
task documentDevtoolsPropertyDefaults(type: org.springframework.boot.build.devtools.DocumentDevtoolsPropertyDefaults) {}
259+
tasks.register("documentDevtoolsPropertyDefaults", org.springframework.boot.build.devtools.DocumentDevtoolsPropertyDefaults) {}
260260

261-
task runRemoteSpringApplicationExample(type: org.springframework.boot.build.docs.ApplicationRunner) {
261+
tasks.register("runRemoteSpringApplicationExample", org.springframework.boot.build.docs.ApplicationRunner) {
262262
classpath = configurations.remoteSpringApplicationExample
263263
mainClass = "org.springframework.boot.devtools.RemoteSpringApplication"
264264
args = ["https://myapp.example.com", "--spring.devtools.remote.secret=secret", "--spring.devtools.livereload.port=0"]
@@ -268,7 +268,7 @@ task runRemoteSpringApplicationExample(type: org.springframework.boot.build.docs
268268
normalizeLiveReloadPort()
269269
}
270270

271-
task runSpringApplicationExample(type: org.springframework.boot.build.docs.ApplicationRunner) {
271+
tasks.register("runSpringApplicationExample", org.springframework.boot.build.docs.ApplicationRunner) {
272272
classpath = configurations.springApplicationExample + sourceSets.main.output
273273
mainClass = "org.springframework.boot.docs.features.logexample.MyApplication"
274274
args = ["--server.port=0"]
@@ -277,7 +277,7 @@ task runSpringApplicationExample(type: org.springframework.boot.build.docs.Appli
277277
normalizeTomcatPort()
278278
}
279279

280-
task runLoggingFormatExample(type: org.springframework.boot.build.docs.ApplicationRunner) {
280+
tasks.register("runLoggingFormatExample", org.springframework.boot.build.docs.ApplicationRunner) {
281281
classpath = configurations.springApplicationExample + sourceSets.main.output
282282
mainClass = "org.springframework.boot.docs.features.logexample.MyApplication"
283283
args = ["--spring.main.banner-mode=off", "--server.port=0", "--spring.application.name=myapp"]

spring-boot-project/spring-boot-test-autoconfigure/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ test {
129129
include "**/*Tests.class"
130130
}
131131

132-
task testSliceMetadata(type: org.springframework.boot.build.test.autoconfigure.TestSliceMetadata) {
132+
tasks.register("testSliceMetadata", org.springframework.boot.build.test.autoconfigure.TestSliceMetadata) {
133133
sourceSet = sourceSets.main
134134
outputFile = layout.buildDirectory.file("test-slice-metadata.properties")
135135
}

spring-boot-project/spring-boot-tools/spring-boot-antlib/build.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ dependencies {
2525
implementation("org.springframework:spring-core")
2626
}
2727

28-
task syncIntegrationTestSources(type: Sync) {
28+
tasks.register("syncIntegrationTestSources", Sync) {
2929
destinationDir = file(layout.buildDirectory.dir("it"))
3030
from file("src/it")
3131
filter(springRepositoryTransformers.ant())
@@ -39,7 +39,7 @@ processResources {
3939
inputs.property "version", version
4040
}
4141

42-
task integrationTest {
42+
tasks.register("integrationTest") {
4343
dependsOn syncIntegrationTestSources, jar
4444
def resultsDir = file(layout.buildDirectory.dir("test-results/integrationTest"))
4545
inputs.dir(file("src/it")).withPathSensitivity(PathSensitivity.RELATIVE).withPropertyName("source")

spring-boot-project/spring-boot-tools/spring-boot-cli/build.gradle

+4-4
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ dependencies {
4646
testImplementation("org.springframework:spring-test")
4747
}
4848

49-
task fullJar(type: Jar) {
49+
tasks.register("fullJar", Jar) {
5050
dependsOn configurations.loader
5151
archiveClassifier = "full"
5252
entryCompression = "stored"
@@ -89,7 +89,7 @@ def configureArchive(archive) {
8989
}
9090
}
9191

92-
task zip(type: Zip) {
92+
tasks.register("zip", Zip) {
9393
archiveClassifier = "bin"
9494
configureArchive it
9595
}
@@ -98,14 +98,14 @@ intTest {
9898
dependsOn zip
9999
}
100100

101-
task tar(type: Tar) {
101+
tasks.register("tar", Tar) {
102102
compression = "gzip"
103103
archiveExtension = "tar.gz"
104104
configureArchive it
105105
}
106106

107107
if (BuildProperties.get(project).buildType() == BuildType.OPEN_SOURCE) {
108-
task homebrewFormula(type: org.springframework.boot.build.cli.HomebrewFormula) {
108+
tasks.register("homebrewFormula", org.springframework.boot.build.cli.HomebrewFormula) {
109109
dependsOn tar
110110
outputDir = layout.buildDirectory.dir("homebrew")
111111
template = file("src/main/homebrew/spring-boot.rb")

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ gradlePlugin {
134134
}
135135
}
136136

137-
task preparePluginValidationClasses(type: Copy) {
137+
tasks.register("preparePluginValidationClasses", Copy) {
138138
destinationDir = layout.buildDirectory.dir("classes/java/pluginValidation").get().asFile
139139
from(sourceSets.main.output.classesDirs) {
140140
exclude "**/CreateBootStartScripts.class"

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/docs/antora/modules/gradle-plugin/examples/getting-started/typical-plugins.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ plugins {
77
apply plugin: 'io.spring.dependency-management'
88
// end::apply[]
99

10-
task verify {
10+
tasks.register("verify") {
1111
doLast {
1212
plugins.getPlugin(org.gradle.api.plugins.JavaPlugin.class)
1313
plugins.getPlugin(io.spring.gradle.dependencymanagement.DependencyManagementPlugin.class)

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/docs/antora/modules/gradle-plugin/examples/managing-dependencies/custom-version.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ repositories {
2424
}
2525
}
2626

27-
task slf4jVersion {
27+
tasks.register("slf4jVersion") {
2828
doLast {
2929
println dependencyManagement.managedVersions['org.slf4j:slf4j-api']
3030
}

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/plugin/DependencyManagementPluginActionIntegrationTests.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ repositories {
2222
}
2323
}
2424

25-
task doesNotHaveDependencyManagement {
25+
tasks.register("doesNotHaveDependencyManagement") {
2626
def extensions = project.extensions
2727
doLast {
2828
if (extensions.findByName('dependencyManagement') != null) {
@@ -31,7 +31,7 @@ task doesNotHaveDependencyManagement {
3131
}
3232
}
3333

34-
task hasDependencyManagement {
34+
tasks.register("hasDependencyManagement") {
3535
doLast {
3636
if (!dependencyManagement.managedVersions) {
3737
throw new GradleException('No managed versions have been configured')

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/plugin/KotlinPluginActionIntegrationTests-kotlinVersionPropertyIsSet.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ dependencies {
2626
implementation('org.jetbrains.kotlin:kotlin-stdlib-jdk8')
2727
}
2828

29-
task kotlinVersion {
29+
tasks.register("kotlinVersion") {
3030
def properties = project.properties
3131
doLast {
3232
def kotlinVersion = properties.getOrDefault('kotlin.version', 'none')

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/plugin/KotlinPluginActionIntegrationTests-noKotlinVersionPropertyWithoutKotlinPlugin.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ plugins {
22
id 'org.springframework.boot' version '{version}'
33
}
44

5-
task kotlinVersion {
5+
tasks.register("kotlinVersion") {
66
def properties = project.properties
77
doLast {
88
def kotlinVersion = properties.getOrDefault('kotlin.version', 'none')

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/tasks/buildinfo/BuildInfoIntegrationTests-basicExecution.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ plugins {
44

55
version = '0.1.0'
66

7-
task buildInfo(type: org.springframework.boot.gradle.tasks.buildinfo.BuildInfo) {
7+
tasks.register("buildInfo", org.springframework.boot.gradle.tasks.buildinfo.BuildInfo) {
88
properties {
99
artifact = 'foo'
1010
group = 'foo'

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/tasks/buildinfo/BuildInfoIntegrationTests-defaultValues.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ plugins {
22
id 'org.springframework.boot' version '{version}' apply false
33
}
44

5-
task buildInfo(type: org.springframework.boot.gradle.tasks.buildinfo.BuildInfo)
5+
tasks.register("buildInfo", org.springframework.boot.gradle.tasks.buildinfo.BuildInfo)

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/tasks/buildinfo/BuildInfoIntegrationTests-excludeProperties.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,6 @@ plugins {
55
group = 'foo'
66
version = '0.1.0'
77

8-
task buildInfo(type: org.springframework.boot.gradle.tasks.buildinfo.BuildInfo) {
8+
tasks.register("buildInfo", org.springframework.boot.gradle.tasks.buildinfo.BuildInfo) {
99
excludes = ['group', 'artifact', 'version', 'name']
1010
}

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/tasks/buildinfo/BuildInfoIntegrationTests-notUpToDateWhenExecutedTwiceAsTimeChanges.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ plugins {
22
id 'org.springframework.boot' version '{version}' apply false
33
}
44

5-
task buildInfo(type: org.springframework.boot.gradle.tasks.buildinfo.BuildInfo)
5+
tasks.register("buildInfo", org.springframework.boot.gradle.tasks.buildinfo.BuildInfo)

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/tasks/buildinfo/BuildInfoIntegrationTests-notUpToDateWhenExecutedTwiceWithFixedTimeAndChangedGradlePropertiesProjectVersion.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ plugins {
22
id 'org.springframework.boot' version '{version}' apply false
33
}
44

5-
task buildInfo(type: org.springframework.boot.gradle.tasks.buildinfo.BuildInfo) {
5+
tasks.register("buildInfo", org.springframework.boot.gradle.tasks.buildinfo.BuildInfo) {
66
excludes = ["time"]
77
properties {
88
artifact = 'example'

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/tasks/buildinfo/BuildInfoIntegrationTests-notUpToDateWhenExecutedTwiceWithFixedTimeAndChangedProjectVersion.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ plugins {
44

55
version = '{projectVersion}'
66

7-
task buildInfo(type: org.springframework.boot.gradle.tasks.buildinfo.BuildInfo) {
7+
tasks.register("buildInfo", org.springframework.boot.gradle.tasks.buildinfo.BuildInfo) {
88
excludes = ["time"]
99
properties {
1010
artifact = 'example'

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/tasks/buildinfo/BuildInfoIntegrationTests-reproducibleOutputWithFixedTime.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@ plugins {
22
id 'org.springframework.boot' version '{version}' apply false
33
}
44

5-
task buildInfo(type: org.springframework.boot.gradle.tasks.buildinfo.BuildInfo) {
5+
tasks.register("buildInfo", org.springframework.boot.gradle.tasks.buildinfo.BuildInfo) {
66
excludes = ["time"]
77
}

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/tasks/buildinfo/BuildInfoIntegrationTests-upToDateWhenExecutedTwiceWithFixedTime.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@ plugins {
22
id 'org.springframework.boot' version '{version}' apply false
33
}
44

5-
task buildInfo(type: org.springframework.boot.gradle.tasks.buildinfo.BuildInfo) {
5+
tasks.register("buildInfo", org.springframework.boot.gradle.tasks.buildinfo.BuildInfo) {
66
excludes = ["time"]
77
}

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/tasks/bundling/BootJarIntegrationTests-customLayers.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -38,13 +38,13 @@ dependencies {
3838
implementation("org.springframework:spring-core:5.2.5.RELEASE")
3939
}
4040

41-
task listLayers(type: JavaExec) {
41+
tasks.register("listLayers", JavaExec) {
4242
classpath = bootJar.outputs.files
4343
systemProperties = [ "jarmode": "tools" ]
4444
args "list-layers"
4545
}
4646

47-
task extractLayers(type: JavaExec) {
47+
tasks.register("extractLayers", JavaExec) {
4848
classpath = bootJar.outputs.files
4949
systemProperties = [ "jarmode": "tools" ]
5050
args "extract", "--layers", "--launcher", "--destination", ".", "--force"

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/tasks/bundling/BootJarIntegrationTests-explodedApplicationClasspath.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,13 @@ dependencies {
1515
implementation("org.apache.commons:commons-lang3:3.9")
1616
}
1717

18-
task explode(type: Sync) {
18+
tasks.register("explode", Sync) {
1919
dependsOn(bootJar)
2020
destinationDir = layout.buildDirectory.dir("exploded").get().asFile
2121
from zipTree(files(bootJar).singleFile)
2222
}
2323

24-
task launch(type: JavaExec) {
24+
tasks.register("launch", JavaExec) {
2525
classpath = files(explode)
2626
mainClass = 'org.springframework.boot.loader.launch.JarLauncher'
2727
}

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/tasks/bundling/BootJarIntegrationTests-implicitLayers.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -21,13 +21,13 @@ dependencies {
2121
implementation("org.springframework.boot:spring-boot-starter-logging:2.2.0.RELEASE")
2222
}
2323

24-
task listLayers(type: JavaExec) {
24+
tasks.register("listLayers", JavaExec) {
2525
classpath = bootJar.outputs.files
2626
systemProperties = [ "jarmode": "tools" ]
2727
args "list-layers"
2828
}
2929

30-
task extractLayers(type: JavaExec) {
30+
tasks.register("extractLayers", JavaExec) {
3131
classpath = bootJar.outputs.files
3232
systemProperties = [ "jarmode": "tools" ]
3333
args "extract", "--layers", "--launcher", "--destination", ".", "--force"

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/tasks/bundling/BootJarIntegrationTests-layersWithCustomSourceSet.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,13 @@ dependencies {
2424
implementation("org.springframework:spring-core:5.2.5.RELEASE")
2525
}
2626

27-
task listLayers(type: JavaExec) {
27+
tasks.register("listLayers", JavaExec) {
2828
classpath = bootJar.outputs.files
2929
systemProperties = [ "jarmode": "tools" ]
3030
args "list-layers"
3131
}
3232

33-
task extractLayers(type: JavaExec) {
33+
tasks.register("extractLayers", JavaExec) {
3434
classpath = bootJar.outputs.files
3535
systemProperties = [ "jarmode": "tools" ]
3636
args "extract", "--layers", "--launcher", "--destination", ".", "--force"

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/tasks/bundling/BootJarIntegrationTests-multiModuleCustomLayers.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -55,13 +55,13 @@ dependencies {
5555
implementation("org.springframework:spring-core:5.2.5.RELEASE")
5656
}
5757

58-
task listLayers(type: JavaExec) {
58+
tasks.register("listLayers", JavaExec) {
5959
classpath = bootJar.outputs.files
6060
systemProperties = [ "jarmode": "tools" ]
6161
args "list-layers"
6262
}
6363

64-
task extractLayers(type: JavaExec) {
64+
tasks.register("extractLayers", JavaExec) {
6565
classpath = bootJar.outputs.files
6666
systemProperties = [ "jarmode": "tools" ]
6767
args "extract", "--layers", "--launcher", "--destination", ".", "--force"

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/tasks/bundling/BootJarIntegrationTests-multiModuleImplicitLayers.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -33,13 +33,13 @@ dependencies {
3333
implementation("org.springframework:spring-core:5.2.5.RELEASE")
3434
}
3535

36-
task listLayers(type: JavaExec) {
36+
tasks.register("listLayers", JavaExec) {
3737
classpath = bootJar.outputs.files
3838
systemProperties = [ "jarmode": "tools" ]
3939
args "list-layers"
4040
}
4141

42-
task extractLayers(type: JavaExec) {
42+
tasks.register("extractLayers", JavaExec) {
4343
classpath = bootJar.outputs.files
4444
systemProperties = [ "jarmode": "tools" ]
4545
args "extract", "--layers", "--launcher", "--destination", ".", "--force"

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/tasks/bundling/BootJarIntegrationTests-packagedApplicationClasspath.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ plugins {
44
id 'org.springframework.boot' version '{version}'
55
}
66

7-
task launch(type: JavaExec) {
7+
tasks.register("launch", JavaExec) {
88
classpath = files(bootJar)
99
}
1010

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/tasks/bundling/BootWarIntegrationTests-customLayers.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -39,13 +39,13 @@ dependencies {
3939
implementation("org.springframework:spring-core:5.2.5.RELEASE")
4040
}
4141

42-
task listLayers(type: JavaExec) {
42+
tasks.register("listLayers", JavaExec) {
4343
classpath = bootWar.outputs.files
4444
systemProperties = [ "jarmode": "tools" ]
4545
args "list-layers"
4646
}
4747

48-
task extractLayers(type: JavaExec) {
48+
tasks.register("extractLayers", JavaExec) {
4949
classpath = bootWar.outputs.files
5050
systemProperties = [ "jarmode": "tools" ]
5151
args "extract", "--layers", "--launcher", "--destination", ".", "--force"

spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/test/resources/org/springframework/boot/gradle/tasks/bundling/BootWarIntegrationTests-implicitLayers.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,13 @@ dependencies {
2222
implementation("org.springframework.boot:spring-boot-starter-logging:2.2.0.RELEASE")
2323
}
2424

25-
task listLayers(type: JavaExec) {
25+
tasks.register("listLayers", JavaExec) {
2626
classpath = bootWar.outputs.files
2727
systemProperties = [ "jarmode": "tools" ]
2828
args "list-layers"
2929
}
3030

31-
task extractLayers(type: JavaExec) {
31+
tasks.register("extractLayers", JavaExec) {
3232
classpath = bootWar.outputs.files
3333
systemProperties = [ "jarmode": "tools" ]
3434
args "extract", "--layers", "--launcher", "--destination", ".", "--force"

0 commit comments

Comments
 (0)