diff --git a/build.gradle.kts b/build.gradle.kts index 77f4554..d82d0c7 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -8,6 +8,5 @@ description = "Rewrite Docker recipes." val rewriteVersion = rewriteRecipe.rewriteVersion.get() dependencies { implementation(platform("org.openrewrite:rewrite-bom:$rewriteVersion")) - implementation("org.openrewrite:rewrite-core") - implementation("org.openrewrite:rewrite-maven") + implementation("org.openrewrite:rewrite-core:$rewriteVersion") } diff --git a/src/main/java/org/openrewrite/docker/search/FindDockerImageUses.java b/src/main/java/org/openrewrite/docker/search/FindDockerImageUses.java index cb64417..a238d61 100644 --- a/src/main/java/org/openrewrite/docker/search/FindDockerImageUses.java +++ b/src/main/java/org/openrewrite/docker/search/FindDockerImageUses.java @@ -21,7 +21,6 @@ import org.openrewrite.docker.DockerImageVersion; import org.openrewrite.docker.table.DockerBaseImages; import org.openrewrite.marker.SearchResult; -import org.openrewrite.maven.table.DependenciesInUse; import java.util.List; import java.util.stream.Collectors; @@ -31,12 +30,6 @@ public class FindDockerImageUses extends Recipe { transient DockerBaseImages dockerBaseImages = new DockerBaseImages(this); - /** - * This is a bit of a stretch, but helps us to use pre-existing visualizations for - * categorizing dependency use. - */ - transient DependenciesInUse dependenciesInUse = new DependenciesInUse(this); - @Override public String getDisplayName() { return "Find uses of docker base images"; @@ -53,14 +46,9 @@ public TreeVisitor getVisitor() { List froms = docker.getFroms(); if (!froms.isEmpty()) { for (DockerImageVersion from : froms) { - String version = from.getVersion() == null ? "" : from.getVersion(); dockerBaseImages.insertRow(ctx, new DockerBaseImages.Row( from.getImageName(), - version - )); - dependenciesInUse.insertRow(ctx, new DependenciesInUse.Row( - "", "docker", "", from.getImageName(), - version, null, "", 0 + from.getVersion() == null ? "" : from.getVersion() )); } return SearchResult.found(docker.getTree(),