[Build] Fix configuration cache problem with embeddable task

#KT-44611 In Progress
This commit is contained in:
Alexander Likhachev
2022-02-21 18:02:31 +03:00
parent aa3b653847
commit 44e92a6134
+3 -2
View File
@@ -7,6 +7,7 @@ import org.gradle.api.artifacts.component.ProjectComponentSelector
import org.gradle.api.attributes.LibraryElements
import org.gradle.api.attributes.Usage
import org.gradle.api.file.DuplicatesStrategy
import org.gradle.api.file.FileCollection
import org.gradle.api.tasks.TaskProvider
import org.gradle.jvm.tasks.Jar
import org.gradle.kotlin.dsl.named
@@ -165,8 +166,8 @@ fun Project.rewriteDepsToShadedJar(
// When Gradle traverses the inputs, reject the shaded compiler JAR,
// which leads to the content of that JAR being excluded as well:
val compilerDummyJarFile = project.provider { project.configurations.getByName("compilerDummyJar").singleFile }
exclude { it.file == compilerDummyJarFile.get() }
val compilerDummyJarConfiguration: FileCollection = project.configurations.getByName("compilerDummyJar")
exclude { it.file == compilerDummyJarConfiguration.singleFile }
archiveClassifier.set("original")
body()