Skip to content

Commit

Permalink
Merge pull request #78 from krzdabrowski/renovate/major-kotlin-monorepo
Browse files Browse the repository at this point in the history
Update kotlin monorepo to v2 (major)
  • Loading branch information
krzdabrowski authored Jun 15, 2024
2 parents 25243bd + b61456e commit 4adab3f
Show file tree
Hide file tree
Showing 7 changed files with 32 additions and 23 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -86,3 +86,6 @@ lint/tmp/

# Build cache
build-cache

# Since Kotlin 2.0.0, folder named ".kotlin" is created at compile time
.kotlin
5 changes: 3 additions & 2 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ plugins {
alias(libs.plugins.detekt)
alias(libs.plugins.hilt)
alias(libs.plugins.kotlin)
alias(libs.plugins.kotlin.compose.compiler)
alias(libs.plugins.ksp)
alias(libs.plugins.ktlint)
}
Expand Down Expand Up @@ -38,8 +39,8 @@ android {
}
}

composeOptions {
kotlinCompilerExtensionVersion = libs.versions.compose.compiler.get()
composeCompiler {
enableStrongSkippingMode = true
}

kotlin {
Expand Down
15 changes: 8 additions & 7 deletions basic-feature/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ plugins {
alias(libs.plugins.detekt)
alias(libs.plugins.junit)
alias(libs.plugins.kotlin)
alias(libs.plugins.kotlin.compose.compiler)
alias(libs.plugins.kotlin.parcelize)
alias(libs.plugins.kotlin.serialization)
alias(libs.plugins.ksp)
Expand Down Expand Up @@ -33,18 +34,18 @@ android {
}
}

composeOptions {
kotlinCompilerExtensionVersion = libs.versions.compose.compiler.get()
composeCompiler {
enableStrongSkippingMode = true
}

kotlin {
jvmToolchain(17)
}

kotlinOptions {
freeCompilerArgs = listOf(
"-opt-in=androidx.compose.material3.ExperimentalMaterial3Api"
)
compilerOptions {
freeCompilerArgs.addAll(
"-opt-in=androidx.compose.material3.ExperimentalMaterial3Api"
)
}
}

sourceSets {
Expand Down
1 change: 1 addition & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ plugins {
alias(libs.plugins.hilt) apply false
alias(libs.plugins.junit) apply false
alias(libs.plugins.kotlin) apply false
alias(libs.plugins.kotlin.compose.compiler) apply false
alias(libs.plugins.kotlin.parcelize) apply false
alias(libs.plugins.kotlin.serialization) apply false
alias(libs.plugins.ksp) apply false
Expand Down
21 changes: 11 additions & 10 deletions core/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ plugins {
alias(libs.plugins.hilt)
alias(libs.plugins.junit)
alias(libs.plugins.kotlin)
alias(libs.plugins.kotlin.compose.compiler)
alias(libs.plugins.ksp)
alias(libs.plugins.ktlint)
}
Expand Down Expand Up @@ -33,21 +34,21 @@ android {
}
}

composeOptions {
kotlinCompilerExtensionVersion = libs.versions.compose.compiler.get()
composeCompiler {
enableStrongSkippingMode = true
}

kotlin {
jvmToolchain(17)
}

kotlinOptions {
freeCompilerArgs = listOf(
"-opt-in=androidx.compose.material3.ExperimentalMaterial3Api",
"-opt-in=kotlinx.coroutines.FlowPreview",
"-opt-in=kotlinx.coroutines.ExperimentalCoroutinesApi",
"-opt-in=kotlinx.serialization.ExperimentalSerializationApi"
)
compilerOptions {
freeCompilerArgs.addAll(
"-opt-in=androidx.compose.material3.ExperimentalMaterial3Api",
"-opt-in=kotlinx.coroutines.FlowPreview",
"-opt-in=kotlinx.coroutines.ExperimentalCoroutinesApi",
"-opt-in=kotlinx.serialization.ExperimentalSerializationApi"
)
}
}
}

Expand Down
3 changes: 2 additions & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,9 @@
org.gradle.caching=true
org.gradle.configuration-cache=true
org.gradle.configureondemand=true
org.gradle.jvmargs=-Xmx6g -Dfile.encoding=UTF-8 -XX:+UseParallelGC
org.gradle.jvmargs=-Xms8g -Xmx10g -Dfile.encoding=UTF-8 -XX:+UseParallelGC
org.gradle.parallel=true
org.gradle.workers.max=5

# Application properties
android.useAndroidX=true
Expand Down
7 changes: 4 additions & 3 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ android-gradle = "8.5.0"
detekt = "1.23.6"
detekt-compose-rules = "0.4.4"
junit = "1.10.0.0"
ksp = "1.9.24-1.0.20"
ksp = "2.0.0-1.0.22"
ktlint = "3.16.0"

# production libraries
Expand All @@ -13,9 +13,9 @@ compose-bom = "2024.06.00"
compose-compiler = "1.5.14"
compose-material3 = "1.2.1"
hilt = "2.51.1"
kotlin = "1.9.24"
kotlin = "2.0.0"
kotlin-coroutines = "1.8.1"
kotlin-serialization = "1.6.3"
kotlin-serialization = "1.7.0"
lifecycle = "2.7.0" # update to 2.8.x when it fixes the crash on release version that happens on 2.8.2
navigation = "2.7.7"
navigation-hilt = "1.2.0"
Expand Down Expand Up @@ -46,6 +46,7 @@ detekt = { id = "io.gitlab.arturbosch.detekt", vers
hilt = { id = "com.google.dagger.hilt.android", version.ref = "hilt" }
junit = { id = "de.mannodermaus.android-junit5", version.ref = "junit" }
kotlin = { id = "org.jetbrains.kotlin.android", version.ref = "kotlin" }
kotlin-compose-compiler = { id = "org.jetbrains.kotlin.plugin.compose", version.ref = "kotlin" }
kotlin-parcelize = { id = "org.jetbrains.kotlin.plugin.parcelize", version.ref = "kotlin" }
kotlin-serialization = { id = "org.jetbrains.kotlin.plugin.serialization", version.ref = "kotlin" }
ksp = { id = "com.google.devtools.ksp", version.ref = "ksp" }
Expand Down

0 comments on commit 4adab3f

Please sign in to comment.