mirror of
https://github.com/jlengrand/compose-multiplatform.git
synced 2026-03-10 08:11:20 +00:00
Use another version of Compose Compiler inside Compose Gradle plugin (#2256)
* Use another version of Compose Compiler inside Compose Gradle plugin * Update gradle.properties
This commit is contained in:
@@ -49,9 +49,6 @@ val iconsComponents =
|
||||
)
|
||||
|
||||
fun ComposePublishingTask.mainPublications() {
|
||||
publish(":compose:compiler:compiler", publications = listOf("Maven"))
|
||||
publish(":compose:compiler:compiler-hosted", publications = listOf("Maven"))
|
||||
|
||||
publish(
|
||||
":compose:desktop:desktop",
|
||||
onlyWithPlatforms = setOf(ComposePlatforms.Desktop),
|
||||
|
||||
@@ -15,6 +15,7 @@ object BuildProperties {
|
||||
fun composeVersion(project: Project): String =
|
||||
System.getenv("COMPOSE_GRADLE_PLUGIN_COMPOSE_VERSION")
|
||||
?: project.findProperty("compose.version") as String
|
||||
fun composeCompilerVersion(project: Project): String = project.findProperty("compose.compiler.version") as String
|
||||
fun deployVersion(project: Project): String =
|
||||
System.getenv("COMPOSE_GRADLE_PLUGIN_VERSION")
|
||||
?: project.findProperty("deploy.version") as String
|
||||
|
||||
@@ -29,6 +29,7 @@ val buildConfig = tasks.register("buildConfig", GenerateBuildConfig::class.java)
|
||||
classFqName.set("org.jetbrains.compose.ComposeBuildConfig")
|
||||
generatedOutputDir.set(buildConfigDir)
|
||||
fieldsToGenerate.put("composeVersion", BuildProperties.composeVersion(project))
|
||||
fieldsToGenerate.put("composeCompilerVersion", BuildProperties.composeCompilerVersion(project))
|
||||
fieldsToGenerate.put("composeGradlePluginVersion", BuildProperties.deployVersion(project))
|
||||
fieldsToGenerate.put("experimentalOELPublication", BuildProperties.experimentalOELPublication(project))
|
||||
fieldsToGenerate.put("oelAndroidXVersion", BuildProperties.oelAndroidXVersion(project).orEmpty())
|
||||
|
||||
@@ -22,7 +22,7 @@ class ComposeCompilerKotlinSupportPlugin : KotlinCompilerPluginSupportPlugin {
|
||||
|
||||
private fun composeCompilerArtifact(artifactId: String) =
|
||||
SubpluginArtifact(
|
||||
groupId = "org.jetbrains.compose.compiler", artifactId = artifactId, version = composeVersion
|
||||
groupId = "org.jetbrains.compose.compiler", artifactId = artifactId, version = ComposeBuildConfig.composeCompilerVersion
|
||||
)
|
||||
|
||||
override fun isApplicable(kotlinCompilation: KotlinCompilation<*>): Boolean =
|
||||
|
||||
@@ -8,6 +8,13 @@ kotlin.code.style=official
|
||||
# __LATEST_COMPOSE_RELEASE_VERSION__
|
||||
compose.version=0.0.0-master-dev673
|
||||
|
||||
compose.compiler.version=1.3.0-alpha01
|
||||
|
||||
# See the corresponding version here: https://developer.android.com/jetpack/androidx/releases/compose-kotlin
|
||||
# (note, that for the 'org.jetbrains.compose` build we usualy keep only Major and Minor versions the same)
|
||||
# This is only used on CI for now.
|
||||
compose.compiler.compatible.kotlin.version=1.7.10
|
||||
|
||||
# A version of Kotlin expected by __LATEST_COMPOSE_RELEASE_VERSION__
|
||||
# This Kotlin version should be used in test or for checking plugin's compatibility,
|
||||
# not for building the Gradle plugin itself!
|
||||
|
||||
Reference in New Issue
Block a user