diff --git a/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/dsl/SpringBootExtension.java b/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/dsl/SpringBootExtension.java index ce2d31e8a4..8cbda847a1 100644 --- a/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/dsl/SpringBootExtension.java +++ b/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/dsl/SpringBootExtension.java @@ -19,17 +19,16 @@ package org.springframework.boot.gradle.dsl; import java.io.File; import java.util.concurrent.Callable; -import javax.swing.Action; - +import org.gradle.api.Action; import org.gradle.api.Project; import org.gradle.api.plugins.BasePlugin; import org.gradle.api.plugins.JavaPlugin; import org.gradle.api.plugins.JavaPluginConvention; import org.gradle.api.tasks.SourceSet; +import org.gradle.jvm.tasks.Jar; import org.springframework.boot.gradle.tasks.buildinfo.BuildInfo; import org.springframework.boot.gradle.tasks.buildinfo.BuildInfoProperties; -import org.springframework.boot.loader.tools.Layouts.Jar; /** * Entry point to Spring Boot's Gradle DSL. @@ -107,7 +106,7 @@ public class SpringBootExtension { private String determineArtifactBaseName() { Jar artifactTask = findArtifactTask(); - return artifactTask == null ? null : artifactTask.getBaseName(); + return (artifactTask == null ? null : artifactTask.getBaseName()); } private Jar findArtifactTask() { diff --git a/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/ApplicationPluginAction.java b/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/ApplicationPluginAction.java index 2594527343..1d6b6220b8 100644 --- a/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/ApplicationPluginAction.java +++ b/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/ApplicationPluginAction.java @@ -23,6 +23,7 @@ import java.io.StringWriter; import java.util.concurrent.Callable; import org.gradle.api.GradleException; +import org.gradle.api.Plugin; import org.gradle.api.Project; import org.gradle.api.distribution.Distribution; import org.gradle.api.distribution.DistributionContainer; diff --git a/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/DependencyManagementPluginAction.java b/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/DependencyManagementPluginAction.java index a9d677ccbe..0bf4cc22f8 100644 --- a/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/DependencyManagementPluginAction.java +++ b/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/DependencyManagementPluginAction.java @@ -18,6 +18,8 @@ package org.springframework.boot.gradle.plugin; import io.spring.gradle.dependencymanagement.DependencyManagementPlugin; import io.spring.gradle.dependencymanagement.dsl.DependencyManagementExtension; +import org.gradle.api.Action; +import org.gradle.api.Plugin; import org.gradle.api.Project; /** diff --git a/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/JavaPluginAction.java b/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/JavaPluginAction.java index b00caf8190..03316c79df 100644 --- a/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/JavaPluginAction.java +++ b/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/JavaPluginAction.java @@ -19,6 +19,8 @@ package org.springframework.boot.gradle.plugin; import java.util.Collections; import java.util.concurrent.Callable; +import org.gradle.api.Action; +import org.gradle.api.Plugin; import org.gradle.api.Project; import org.gradle.api.file.FileCollection; import org.gradle.api.internal.artifacts.publish.ArchivePublishArtifact; diff --git a/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/MavenPluginAction.java b/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/MavenPluginAction.java index 9f69d63e10..ae88b856a2 100644 --- a/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/MavenPluginAction.java +++ b/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/MavenPluginAction.java @@ -16,6 +16,8 @@ package org.springframework.boot.gradle.plugin; +import org.gradle.api.Action; +import org.gradle.api.Plugin; import org.gradle.api.Project; import org.gradle.api.artifacts.maven.MavenResolver; import org.gradle.api.plugins.MavenPlugin; diff --git a/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/SpringBootPlugin.java b/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/SpringBootPlugin.java index 82016cd0e3..1d382b964e 100644 --- a/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/SpringBootPlugin.java +++ b/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/SpringBootPlugin.java @@ -19,9 +19,10 @@ package org.springframework.boot.gradle.plugin; import java.util.Arrays; import java.util.List; -import net.bytebuddy.build.Plugin; import org.gradle.api.GradleException; +import org.gradle.api.Plugin; import org.gradle.api.Project; +import org.gradle.api.artifacts.Configuration; import org.gradle.util.GradleVersion; import org.springframework.boot.gradle.dsl.SpringBootExtension; @@ -39,7 +40,6 @@ public class SpringBootPlugin implements Plugin { /** * The name of the {@link Configuration} that contains Spring Boot archives. - * * @since 2.0.0 */ public static final String BOOT_ARCHIVES_CONFIGURATION_NAME = "bootArchives"; diff --git a/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/tasks/bundling/BootArchiveSupport.java b/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/tasks/bundling/BootArchiveSupport.java index 364072bfb5..0dabcaf3cf 100644 --- a/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/tasks/bundling/BootArchiveSupport.java +++ b/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/tasks/bundling/BootArchiveSupport.java @@ -23,19 +23,18 @@ import java.util.Set; import java.util.TreeMap; import java.util.function.Function; -import javax.swing.text.DefaultEditorKit.CopyAction; - -import io.spring.gradle.dependencymanagement.org.apache.maven.model.PatternSet; import org.gradle.api.file.FileCopyDetails; import org.gradle.api.file.FileTreeElement; import org.gradle.api.file.RelativePath; +import org.gradle.api.internal.file.copy.CopyAction; import org.gradle.api.internal.file.copy.CopyActionProcessingStream; import org.gradle.api.internal.file.copy.FileCopyDetailsInternal; +import org.gradle.api.java.archives.Attributes; import org.gradle.api.specs.Spec; import org.gradle.api.specs.Specs; import org.gradle.api.tasks.WorkResult; - -import org.springframework.boot.loader.tools.Layouts.Jar; +import org.gradle.api.tasks.bundling.Jar; +import org.gradle.api.tasks.util.PatternSet; /** * Support class for implementations of {@link BootArchive}. diff --git a/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/tasks/bundling/BootJar.java b/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/tasks/bundling/BootJar.java index bd979175b7..fdd1b4e3b6 100644 --- a/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/tasks/bundling/BootJar.java +++ b/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/tasks/bundling/BootJar.java @@ -20,16 +20,14 @@ import java.io.File; import java.util.Collections; import java.util.concurrent.Callable; -import javax.swing.Action; -import javax.swing.text.DefaultEditorKit.CopyAction; - +import org.gradle.api.Action; import org.gradle.api.file.CopySpec; import org.gradle.api.file.FileCollection; import org.gradle.api.file.FileCopyDetails; import org.gradle.api.file.FileTreeElement; +import org.gradle.api.internal.file.copy.CopyAction; import org.gradle.api.specs.Spec; - -import org.springframework.boot.loader.tools.Layouts.Jar; +import org.gradle.api.tasks.bundling.Jar; /** * A custom {@link Jar} task that produces a Spring Boot executable jar. diff --git a/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/tasks/bundling/BootWar.java b/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/tasks/bundling/BootWar.java index 500fc11300..558361ad18 100644 --- a/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/tasks/bundling/BootWar.java +++ b/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/tasks/bundling/BootWar.java @@ -20,17 +20,15 @@ import java.io.File; import java.util.Collections; import java.util.concurrent.Callable; -import javax.swing.Action; -import javax.swing.text.DefaultEditorKit.CopyAction; - +import org.gradle.api.Action; import org.gradle.api.Project; import org.gradle.api.file.FileCollection; import org.gradle.api.file.FileCopyDetails; import org.gradle.api.file.FileTreeElement; +import org.gradle.api.internal.file.copy.CopyAction; import org.gradle.api.specs.Spec; import org.gradle.api.tasks.Optional; - -import org.springframework.boot.loader.tools.Layouts.War; +import org.gradle.api.tasks.bundling.War; /** * A custom {@link War} task that produces a Spring Boot executable war.