Skip to content

Commit

Permalink
Kotlin 2.0.0-RC1
Browse files Browse the repository at this point in the history
And migrate to the new Compose compiler plugin
  • Loading branch information
SimonMarquis committed Apr 30, 2024
1 parent 856a7cd commit 0aada8a
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 18 deletions.
3 changes: 1 addition & 2 deletions .github/dependabot.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,11 @@ updates:
registries: "*"
labels: [ ]
groups:
kotlin-ksp-compose:
kotlin-ksp:
patterns:
- "org.jetbrains.kotlin:*"
- "org.jetbrains.kotlin.jvm"
- "com.google.devtools.ksp"
- "androidx.compose.compiler:compiler"
android-build-tools:
patterns:
- "com.android.tools.build:*"
Expand Down
1 change: 1 addition & 0 deletions build-logic/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ dependencies {
compileOnly(libs.gradlePlugins.android)
compileOnly(libs.gradlePlugins.kotlin)
compileOnly(libs.gradlePlugins.ksp)
compileOnly(libs.gradlePlugins.compose)
compileOnly(libs.gradlePlugins.dependencyGuard)
compileOnly(libs.gradlePlugins.dokka)
compileOnly(libs.gradlePlugins.spotless)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,11 @@ internal class SparkAndroidComposePlugin : Plugin<Project> {
override fun apply(target: Project) {
with(target) {
apply(plugin = "org.jetbrains.kotlin.android")
apply(plugin = "org.jetbrains.kotlin.plugin.compose")
apply(plugin = "com.adevinta.spark.android")

android {
buildFeatures.compose = true
composeOptions {
kotlinCompilerExtensionVersion = spark().versions.`androidx-compose-compiler`.toString()
}
}

dependencies {
Expand Down
1 change: 1 addition & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ plugins {
alias(libs.plugins.dokka) apply false
alias(libs.plugins.dependencyGuard) apply false
alias(libs.plugins.spotless) apply false
alias(libs.plugins.compose) apply false

id("com.adevinta.spark.root")
id("com.adevinta.spark.dokka")
Expand Down
8 changes: 4 additions & 4 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ android-gradlePlugin = "8.3.2"
androidx-activity = "1.9.0"
androidx-appCompat = "1.6.1"
androidx-compose-bom = "2024.04.01"
androidx-compose-compiler = "1.5.13-dev-k2.0.0-RC1-50f08dfa4b4"
androidx-lifecycle = "2.7.0"
androidx-navigation = "2.7.7"
androidx-savedstate = "1.2.1"
Expand All @@ -16,11 +15,11 @@ datastore = "1.1.0"
dependencyGuard = "0.5.0"
dokka = "1.9.20"
junit = "4.13.2"
kotlin = "2.0.0-RC1"
kotlin = "2.0.0-RC2"
kotlinx-coroutines = "1.8.0"
kotlinx-collections-immutable = "0.3.7"
kotlinx-serialization-json = "1.6.3"
ksp = "2.0.0-RC1-1.0.20"
ksp = "2.0.0-RC2-1.0.20"
ktlint = "1.2.1"
lint = "31.3.2"
minCompileSdk = "24"
Expand Down Expand Up @@ -49,7 +48,6 @@ androidx-activity-compose = { module = "androidx.activity:activity-compose", ver
androidx-appCompat = { module = "androidx.appcompat:appcompat", version.ref = "androidx-appCompat" }
androidx-appCompat-resources = { module = "androidx.appcompat:appcompat-resources", version.ref = "androidx-appCompat" }
androidx-compose-bom = { module = "androidx.compose:compose-bom", version.ref = "androidx-compose-bom" }
androidx-compose-compiler = { group = "androidx.compose.compiler", name = "compiler", version.ref = "androidx-compose-compiler" }
androidx-compose-foundation = { module = "androidx.compose.foundation:foundation" }
androidx-compose-foundation-layout = { module = "androidx.compose.foundation:foundation-layout" }
androidx-compose-material-iconsExtended = { module = "androidx.compose.material:material-icons-extended" }
Expand Down Expand Up @@ -88,6 +86,7 @@ dokka-android-documentation-plugin = { module = "org.jetbrains.dokka:android-doc
dokka-base = { module = "org.jetbrains.dokka:dokka-base", version.ref = "dokka" }

gradlePlugins-android = { module = "com.android.tools.build:gradle", version.ref = "android-gradlePlugin" }
gradlePlugins-compose = { module = "org.jetbrains.kotlin:compose-compiler-gradle-plugin", version.ref = "kotlin" }
gradlePlugins-dependencyGuard = { module = "com.dropbox.dependency-guard:com.dropbox.dependency-guard.gradle.plugin", version.ref = "dependencyGuard" }
gradlePlugins-dokka = { module = "org.jetbrains.dokka:dokka-gradle-plugin", version.ref = "dokka" }
gradlePlugins-kotlin = { module = "org.jetbrains.kotlin:kotlin-gradle-plugin", version.ref = "kotlin" }
Expand Down Expand Up @@ -126,6 +125,7 @@ android-kotlin = { id = "org.jetbrains.kotlin.android", version.ref = "kotlin" }
android-library = { id = "com.android.library", version.ref = "android-gradlePlugin" }
android-lint = { id = "com.android.lint", version.ref = "android-gradlePlugin" }
android-test = { id = "com.android.test", version.ref = "android-gradlePlugin" }
compose = { id = "org.jetbrains.kotlin.plugin.compose", version.ref = "kotlin" }
paparazzi = { id = "app.cash.paparazzi", version.ref = "paparazzi" }
dependencyGuard = { id = "com.dropbox.dependency-guard", version.ref = "dependencyGuard" }
dokka = { id = "org.jetbrains.dokka", version.ref = "dokka" }
Expand Down
9 changes: 0 additions & 9 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -33,15 +33,6 @@ dependencyResolutionManagement {
repositories {
google()
mavenCentral()

// Pre-release artifacts of compose-compiler
// https://androidx.dev/storage/compose-compiler/repository
maven("https://androidx.dev/storage/compose-compiler/repository/") {
name = "compose-compiler-dev"
content {
includeGroup("androidx.compose.compiler")
}
}
}
}

Expand Down

0 comments on commit 0aada8a

Please sign in to comment.