Skip to content

Commit

Permalink
Move to Compose Compiler plugin, update compileSdk, Gradle, AGP, Kotl…
Browse files Browse the repository at this point in the history
…in and dependencies

compileSdk: 34 -> 35

Gradle: 8.10 -> 8.10.1
AGP: 8.5.2 -> 8.6.0
Kotlin: 1.9.24 -> 2.0.0

Lifecycle Runtime KTX: 2.8.4 -> 2.8.5

Compose BOM: 2024.08.00 -> 2024.09.01
Activity Compose: 1.9.1 -> 1.9.2
Navigation Compose: 2.7.7 -> 2.8.0
  • Loading branch information
MateusRodCosta committed Sep 10, 2024
1 parent d41d13b commit 9632203
Show file tree
Hide file tree
Showing 5 changed files with 34 additions and 35 deletions.
2 changes: 1 addition & 1 deletion .idea/kotlinc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

16 changes: 7 additions & 9 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import java.util.Properties

plugins {
alias(libs.plugins.androidApplication)
alias(libs.plugins.kotlinAndroid)
alias(libs.plugins.android.application)
alias(libs.plugins.kotlin.android)
alias(libs.plugins.compose.compiler)
}

val keystorePropertiesFile = rootProject.file("key.properties")
Expand All @@ -17,7 +18,7 @@ kotlin {

android {
namespace = "com.mateusrodcosta.apps.share2storage"
compileSdk = 34
compileSdk = 35

defaultConfig {
applicationId = "com.mateusrodcosta.apps.share2storage"
Expand Down Expand Up @@ -72,9 +73,6 @@ android {
buildFeatures {
compose = true
}
composeOptions {
kotlinCompilerExtensionVersion = libs.versions.androidxComposeCompiler.get()
}
packaging {
resources {
excludes += "/META-INF/{AL2.0,LGPL2.1}"
Expand All @@ -83,17 +81,17 @@ android {
}

dependencies {
implementation(libs.kotlinx.coroutines)
implementation(libs.coroutines)
implementation(libs.bundles.androidx.ktx)
implementation(libs.androidx.core.splashscreen)
implementation(libs.splashscreen)

val composeBom = platform(libs.compose.bom)
implementation(composeBom)
androidTestImplementation(composeBom)

implementation(libs.bundles.compose)
debugImplementation(libs.bundles.compose.debug)
implementation(libs.bundles.androidx.compose.integration)
implementation(libs.bundles.compose.integration)

testImplementation(libs.bundles.testing)
androidTestImplementation(libs.bundles.ui.testing)
Expand Down
5 changes: 3 additions & 2 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
plugins {
alias(libs.plugins.androidApplication) apply false
alias(libs.plugins.kotlinAndroid) apply false
alias(libs.plugins.android.application) apply false
alias(libs.plugins.kotlin.android) apply false
alias(libs.plugins.compose.compiler) apply false
}
42 changes: 21 additions & 21 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -1,25 +1,24 @@
[versions]
agp = "8.5.2"
kotlin = "1.9.24"
androidxComposeCompiler = "1.5.14"
agp = "8.6.0"
kotlin = "2.0.0"
ktx = "1.13.1"
preference-ktx = "1.2.1"
lifecycle-runtime-ktx = "2.8.4"
lifecycle-runtime-ktx = "2.8.5"
splashscreen = "1.0.1"
composeBom = "2024.08.00"
activityCompose = "1.9.1"
navigationCompose = "2.7.7"
composeBom = "2024.09.01"
activityCompose = "1.9.2"
navigationCompose = "2.8.0"
junit = "4.13.2"
androidxTestRunner = "1.6.2"
androidxTestRules = "1.6.1"
coroutines = "1.7.3"

[libraries]
kotlinx-coroutines = { group = "org.jetbrains.kotlinx", name = "kotlinx-coroutines-android", version.ref = "coroutines" }
androidx-core-ktx = { group = "androidx.core", name = "core-ktx", version.ref = "ktx" }
androidx-preference-ktx = { group = "androidx.preference", name = "preference-ktx", version.ref = "preference-ktx" }
androidx-lifecycle-runtime-ktx = { group = "androidx.lifecycle", name = "lifecycle-runtime-ktx", version.ref = "lifecycle-runtime-ktx" }
androidx-core-splashscreen = { group = "androidx.core", name = "core-splashscreen", version.ref = "splashscreen" }
coroutines = { group = "org.jetbrains.kotlinx", name = "kotlinx-coroutines-android", version.ref = "coroutines" }
core-ktx = { group = "androidx.core", name = "core-ktx", version.ref = "ktx" }
preference-ktx = { group = "androidx.preference", name = "preference-ktx", version.ref = "preference-ktx" }
lifecycle-runtime-ktx = { group = "androidx.lifecycle", name = "lifecycle-runtime-ktx", version.ref = "lifecycle-runtime-ktx" }
splashscreen = { group = "androidx.core", name = "core-splashscreen", version.ref = "splashscreen" }
compose-bom = { group = "androidx.compose", name = "compose-bom", version.ref = "composeBom" }
compose-material3 = { group = "androidx.compose.material3", name = "material3" }
compose-material3-window-size-classes = { group = "androidx.compose.material3", name = "material3-window-size-class" }
Expand All @@ -28,20 +27,21 @@ compose-ui-tooling = { group = "androidx.compose.ui", name = "ui-tooling" }
compose-ui-tooling-preview = { group = "androidx.compose.ui", name = "ui-tooling-preview" }
compose-ui-test-junit4 = { group = "androidx.compose.ui", name = "ui-test-junit4" }
compose-ui-test-manifest = { group = "androidx.compose.ui", name = "ui-test-manifest" }
androidx-activity-compose = { group = "androidx.activity", name = "activity-compose", version.ref = "activityCompose" }
androidx-navigation-compose = { group = "androidx.navigation", name = "navigation-compose", version.ref = "navigationCompose" }
activity-compose = { group = "androidx.activity", name = "activity-compose", version.ref = "activityCompose" }
navigation-compose = { group = "androidx.navigation", name = "navigation-compose", version.ref = "navigationCompose" }
junit = { group = "junit", name = "junit", version.ref = "junit" }
androidx-test-runner = { group = "androidx.test", name="runner", version.ref = "androidxTestRunner" }
androidx-test-rules = { group = "androidx.test", name="rules", version.ref = "androidxTestRules" }
test-runner = { group = "androidx.test", name="runner", version.ref = "androidxTestRunner" }
test-rules = { group = "androidx.test", name="rules", version.ref = "androidxTestRules" }

[bundles]
androidx-ktx = ["androidx.core.ktx", "androidx.preference.ktx", "androidx.lifecycle.runtime.ktx"]
androidx-ktx = ["core.ktx", "preference.ktx", "lifecycle.runtime.ktx"]
compose = ["compose.material3", "compose.material3.window.size.classes", "compose.ui.tooling.preview", "compose.ui.material.icons.extended"]
compose-debug = ["compose.ui.tooling", "compose.ui.test.manifest"]
androidx-compose-integration = ["androidx.activity.compose", "androidx.navigation.compose"]
compose-integration = ["activity.compose", "navigation.compose"]
testing = ["junit"]
ui-testing = ["androidx.test.runner", "androidx.test.rules", "compose.ui.test.junit4"]
ui-testing = ["test.runner", "test.rules", "compose.ui.test.junit4"]

[plugins]
androidApplication = { id = "com.android.application", version.ref = "agp" }
kotlinAndroid = { id = "org.jetbrains.kotlin.android", version.ref = "kotlin" }
android-application = { id = "com.android.application", version.ref = "agp" }
kotlin-android = { id = "org.jetbrains.kotlin.android", version.ref = "kotlin" }
compose-compiler = { id = "org.jetbrains.kotlin.plugin.compose", version.ref = "kotlin" }
4 changes: 2 additions & 2 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionSha256Sum=5b9c5eb3f9fc2c94abaea57d90bd78747ca117ddbbf96c859d3741181a12bf2a
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10-bin.zip
distributionSha256Sum=1541fa36599e12857140465f3c91a97409b4512501c26f9631fb113e392c5bd1
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.1-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
Expand Down

0 comments on commit 9632203

Please sign in to comment.