[Gradle] Move publishableSources flag to InternalKotlinTarget

^KT-55881 Verification Pending
This commit is contained in:
Anton Lakotka
2023-02-19 19:17:27 +01:00
committed by Space Team
parent 4329b66c60
commit 9f32d916f9
3 changed files with 5 additions and 3 deletions
@@ -67,7 +67,7 @@ abstract class AbstractKotlinTarget(
override val publishable: Boolean
get() = true
internal var publishableSources: Boolean = true
override var publishableSources: Boolean = true
override fun withSourcesJar(publish: Boolean) {
publishableSources = publish
}
@@ -11,6 +11,7 @@ import org.jetbrains.kotlin.gradle.plugin.KotlinTargetComponent
import org.jetbrains.kotlin.tooling.core.HasMutableExtras
internal interface InternalKotlinTarget : KotlinTarget, HasMutableExtras {
var publishableSources: Boolean
val kotlinComponents: Set<KotlinTargetComponent>
fun onPublicationCreated(publication: MavenPublication)
}
@@ -58,9 +58,10 @@ internal class ExternalKotlinTargetImpl internal constructor(
artifactsTaskLocator.locate(this)
}
private var publishSources: Boolean = true
override var publishableSources: Boolean = true
override fun withSourcesJar(publish: Boolean) {
publishSources = publish
publishableSources = publish
}
override val artifactsTaskName: String