Skip to content

Commit

Permalink
Update Kotlin to 1.9.20-Beta2 and other deps
Browse files Browse the repository at this point in the history
  • Loading branch information
terrakok committed Oct 10, 2023
1 parent 962f056 commit ba7829f
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 31 deletions.
6 changes: 3 additions & 3 deletions androidApp/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@ plugins {
}

android {
compileSdk = 33
compileSdk = 34
defaultConfig {
applicationId = "com.jetbrains.androidApp"
minSdk = 21
targetSdk = 33
targetSdk = 34
versionCode = 1
versionName = "1.0"
}
Expand All @@ -29,7 +29,7 @@ android {

dependencies {
implementation(project(":shared"))
implementation("com.google.android.material:material:1.9.0")
implementation("com.google.android.material:material:1.10.0")
implementation("androidx.appcompat:appcompat:1.6.1")
implementation("androidx.constraintlayout:constraintlayout:2.1.4")
}
27 changes: 6 additions & 21 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,22 +1,7 @@
buildscript {
repositories {
gradlePluginPortal()
google()
mavenCentral()
}
dependencies {
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:1.8.21")
classpath("com.android.tools.build:gradle:8.0.2")
}
}

allprojects {
repositories {
google()
mavenCentral()
}
}

tasks.register("clean", Delete::class) {
delete(rootProject.buildDir)
plugins {
//trick: for the same plugin versions in all sub-modules
id("com.android.application").version("8.1.2").apply(false)
id("com.android.library").version("8.1.2").apply(false)
kotlin("android").version("1.9.20-Beta2").apply(false)
kotlin("multiplatform").version("1.9.20-Beta2").apply(false)
}
4 changes: 2 additions & 2 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
#Gradle
org.gradle.jvmargs=-Xmx2048M -Dkotlin.daemon.jvm.options\="-Xmx2048M"
org.gradle.jvmargs=-Xmx2048M -Dfile.encoding=UTF-8 -Dkotlin.daemon.jvm.options\="-Xmx2048M"

#Kotlin
kotlin.code.style=official

#Android
android.useAndroidX=true
android.nonTransitiveRClass=true

#MPP
kotlin.mpp.androidSourceSetLayoutVersion=2
kotlin.mpp.enableCInteropCommonization=true
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip
7 changes: 7 additions & 0 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,13 @@ pluginManagement {
}
}

dependencyResolutionManagement {
repositories {
google()
mavenCentral()
}
}

rootProject.name = "KmmSample"

include(":androidApp")
Expand Down
6 changes: 2 additions & 4 deletions shared/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,7 @@ plugins {
}

kotlin {
targetHierarchy.default()

android() {
androidTarget {
compilations.all {
kotlinOptions {
jvmTarget = "1.8"
Expand All @@ -25,7 +23,7 @@ kotlin {
}

sourceSets {
val commonTest by getting {
commonTest {
dependencies {
implementation(kotlin("test-common"))
implementation(kotlin("test-annotations-common"))
Expand Down

0 comments on commit ba7829f

Please sign in to comment.