Update dependencies to latest + migrate to AGP 9.x
Kotlin 2.1.0->2.4.10, Compose Multiplatform 1.7.3->1.11.1, AGP 8.7.3->9.3.1, Gradle 8.10.2->9.7.1. The two libs that pinned us to Compose 1.7.x -- compose-webview-multiplatform (1.9.40->2.0.3) and multiplatform-markdown-renderer (0.33.0->0.44.0) -- now have Compose 1.8+ releases, so the whole stack moves. Also coroutines/serialization 1.11.0, okhttp 5.5.0, media3 1.11.0, activity-compose 1.13.0, firebase-messaging 25.1.2, compose-bom 2026.08.00, google-services 4.5.0, KCEF 2025.03.23 (JBR pin ->17.0.14); material3 1.9.0 / material-icons-extended 1.7.3 (each one's latest stable -- they lag the core).
AGP 9 migration: :shared swaps com.android.library->com.android.kotlin.multiplatform.library (android config moves into kotlin{android{}}, withHostTest{} keeps host tests); :androidApp drops kotlin(android) for AGP 9 built-in Kotlin. compileSdk 34->37 (minSdk stays 29 / Android 10).
Code fixes for API breaks: markdown link->textLink + highlights->highlightsBuilder; kotlinOptions{jvmTarget}->compilerOptions{jvmTarget}.
This commit is contained in:
1 parent
ec53769325
commit
96b60daf08
7 files changed
+60
-54
No files matched your search
@@ -1,12 +1,13 @@
|
|||||||
|
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
|
||||||
|
|
||||||
plugins {
|
plugins {
|
||||||
id("com.android.application")
|
id("com.android.application")
|
||||||
kotlin("android")
|
|
||||||
id("org.jetbrains.kotlin.plugin.compose")
|
id("org.jetbrains.kotlin.plugin.compose")
|
||||||
}
|
}
|
||||||
|
|
||||||
android {
|
android {
|
||||||
namespace = "dev.iris.app"
|
namespace = "dev.iris.app"
|
||||||
compileSdk = 34
|
compileSdk = 37
|
||||||
|
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
applicationId = "dev.iris.app"
|
applicationId = "dev.iris.app"
|
||||||
@@ -26,18 +27,20 @@ android {
|
|||||||
sourceCompatibility = JavaVersion.VERSION_17
|
sourceCompatibility = JavaVersion.VERSION_17
|
||||||
targetCompatibility = JavaVersion.VERSION_17
|
targetCompatibility = JavaVersion.VERSION_17
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
kotlinOptions {
|
kotlin {
|
||||||
jvmTarget = "17"
|
compilerOptions {
|
||||||
|
jvmTarget.set(JvmTarget.JVM_17)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
implementation(project(":shared"))
|
implementation(project(":shared"))
|
||||||
implementation(platform("androidx.compose:compose-bom:2024.09.02"))
|
implementation(platform("androidx.compose:compose-bom:2026.08.00"))
|
||||||
implementation("androidx.compose.material3:material3")
|
implementation("androidx.compose.material3:material3")
|
||||||
implementation("androidx.compose.ui:ui")
|
implementation("androidx.compose.ui:ui")
|
||||||
implementation("androidx.activity:activity-compose:1.9.2")
|
implementation("androidx.activity:activity-compose:1.13.0")
|
||||||
implementation("androidx.core:core-splashscreen:1.0.1")
|
implementation("androidx.core:core-splashscreen:1.0.1")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -7,19 +7,18 @@ buildscript {
|
|||||||
mavenCentral()
|
mavenCentral()
|
||||||
}
|
}
|
||||||
dependencies {
|
dependencies {
|
||||||
classpath("com.google.gms:google-services:4.4.2")
|
classpath("com.google.gms:google-services:4.5.0")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
plugins {
|
plugins {
|
||||||
kotlin("multiplatform") version "2.1.0" apply false
|
kotlin("multiplatform") version "2.4.10" apply false
|
||||||
kotlin("android") version "2.1.0" apply false
|
kotlin("jvm") version "2.4.10" apply false
|
||||||
kotlin("jvm") version "2.1.0" apply false
|
kotlin("plugin.serialization") version "2.4.10" apply false
|
||||||
kotlin("plugin.serialization") version "2.1.0" apply false
|
id("com.android.application") version "9.3.1" apply false
|
||||||
id("com.android.application") version "8.7.3" apply false
|
id("com.android.kotlin.multiplatform.library") version "9.3.1" apply false
|
||||||
id("com.android.library") version "8.7.3" apply false
|
id("org.jetbrains.compose") version "1.11.1" apply false
|
||||||
id("org.jetbrains.compose") version "1.7.3" apply false
|
id("org.jetbrains.kotlin.plugin.compose") version "2.4.10" apply false
|
||||||
id("org.jetbrains.kotlin.plugin.compose") version "2.1.0" apply false
|
|
||||||
}
|
}
|
||||||
|
|
||||||
tasks.register("clean") {
|
tasks.register("clean") {
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ plugins {
|
|||||||
id("org.jetbrains.kotlin.plugin.compose")
|
id("org.jetbrains.kotlin.plugin.compose")
|
||||||
}
|
}
|
||||||
|
|
||||||
val composeVersion = "1.7.3"
|
val composeVersion = "1.11.1"
|
||||||
val os = OperatingSystem.current()
|
val os = OperatingSystem.current()
|
||||||
val arch = System.getProperty("os.arch") ?: "amd64"
|
val arch = System.getProperty("os.arch") ?: "amd64"
|
||||||
val desktopTarget = when {
|
val desktopTarget = when {
|
||||||
@@ -19,7 +19,7 @@ dependencies {
|
|||||||
implementation(project(":shared"))
|
implementation(project(":shared"))
|
||||||
implementation("org.jetbrains.compose.desktop:desktop-jvm-$desktopTarget:$composeVersion")
|
implementation("org.jetbrains.compose.desktop:desktop-jvm-$desktopTarget:$composeVersion")
|
||||||
// M6: window-state persistence (window.json).
|
// M6: window-state persistence (window.json).
|
||||||
implementation("org.jetbrains.kotlinx:kotlinx-serialization-json:1.7.3")
|
implementation("org.jetbrains.kotlinx:kotlinx-serialization-json:1.11.0")
|
||||||
}
|
}
|
||||||
|
|
||||||
compose.desktop {
|
compose.desktop {
|
||||||
|
|||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
distributionBase=GRADLE_USER_HOME
|
distributionBase=GRADLE_USER_HOME
|
||||||
distributionPath=wrapper/dists
|
distributionPath=wrapper/dists
|
||||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-bin.zip
|
distributionUrl=https\://services.gradle.org/distributions/gradle-9.7.1-bin.zip
|
||||||
networkTimeout=10000
|
networkTimeout=10000
|
||||||
validateDistributionUrl=true
|
validateDistributionUrl=true
|
||||||
zipStoreBase=GRADLE_USER_HOME
|
zipStoreBase=GRADLE_USER_HOME
|
||||||
|
|||||||
+34
-32
@@ -1,27 +1,41 @@
|
|||||||
|
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
|
||||||
|
|
||||||
plugins {
|
plugins {
|
||||||
kotlin("multiplatform")
|
kotlin("multiplatform")
|
||||||
kotlin("plugin.serialization")
|
kotlin("plugin.serialization")
|
||||||
id("com.android.library")
|
id("com.android.kotlin.multiplatform.library")
|
||||||
id("org.jetbrains.compose")
|
id("org.jetbrains.compose")
|
||||||
id("org.jetbrains.kotlin.plugin.compose")
|
id("org.jetbrains.kotlin.plugin.compose")
|
||||||
}
|
}
|
||||||
|
|
||||||
val composeVersion = "1.7.3"
|
val composeVersion = "1.11.1"
|
||||||
val coroutinesVersion = "1.9.0"
|
// material3 and material-icons-extended are published on their own cadence and
|
||||||
val serializationVersion = "1.7.3"
|
// lag the core artifacts; use each one's latest stable release.
|
||||||
val okhttpVersion = "4.12.0"
|
val material3Version = "1.9.0"
|
||||||
// Pinned to 1.9.40: the last release built against Compose 1.7.x (1.7.1);
|
val materialIconsVersion = "1.7.3"
|
||||||
// 2.0.x moves to Compose 1.8+. HTML artifact previews (M9): Android uses the
|
val coroutinesVersion = "1.11.0"
|
||||||
|
val serializationVersion = "1.11.0"
|
||||||
|
val okhttpVersion = "5.5.0"
|
||||||
|
// 2.0.x is the first line built against Compose 1.8+ (1.9.40 was the last
|
||||||
|
// 1.7.x-compatible release). HTML artifact previews (M9): Android uses the
|
||||||
// platform WebView, desktop uses KCEF (JCEF/Chromium, downloaded on first use).
|
// platform WebView, desktop uses KCEF (JCEF/Chromium, downloaded on first use).
|
||||||
val webviewVersion = "1.9.40"
|
val webviewVersion = "2.0.3"
|
||||||
val kcefVersion = "2024.04.20.3"
|
val kcefVersion = "2025.03.23"
|
||||||
// Pinned to 0.33.0: the last release built against Compose 1.7.x / Kotlin 2.1.x
|
// 0.34.0+ moved to Compose 1.8+ (0.33.0 was the last 1.7.x / Kotlin 2.1.x
|
||||||
// (0.34.0+ moves to Compose 1.8+). Provides GFM tables, bold/italic/underscore,
|
// release). Provides GFM tables, bold/italic/underscore, and the -code module
|
||||||
// and the -code module for language-aware syntax highlighting (Highlights).
|
// for language-aware syntax highlighting (Highlights).
|
||||||
val markdownVersion = "0.33.0"
|
val markdownVersion = "0.44.0"
|
||||||
|
|
||||||
kotlin {
|
kotlin {
|
||||||
androidTarget()
|
android {
|
||||||
|
namespace = "iris.shared"
|
||||||
|
compileSdk = 37
|
||||||
|
minSdk = 29
|
||||||
|
compilerOptions {
|
||||||
|
jvmTarget.set(JvmTarget.JVM_17)
|
||||||
|
}
|
||||||
|
withHostTest { }
|
||||||
|
}
|
||||||
jvm("desktop")
|
jvm("desktop")
|
||||||
|
|
||||||
sourceSets {
|
sourceSets {
|
||||||
@@ -34,11 +48,11 @@ kotlin {
|
|||||||
commonMain.dependencies {
|
commonMain.dependencies {
|
||||||
implementation("org.jetbrains.compose.runtime:runtime:$composeVersion")
|
implementation("org.jetbrains.compose.runtime:runtime:$composeVersion")
|
||||||
implementation("org.jetbrains.compose.foundation:foundation:$composeVersion")
|
implementation("org.jetbrains.compose.foundation:foundation:$composeVersion")
|
||||||
implementation("org.jetbrains.compose.material3:material3:$composeVersion")
|
implementation("org.jetbrains.compose.material3:material3:$material3Version")
|
||||||
implementation("org.jetbrains.compose.ui:ui:$composeVersion")
|
implementation("org.jetbrains.compose.ui:ui:$composeVersion")
|
||||||
// Full Material icon set (Icons.Filled.ContentCopy for the code
|
// Full Material icon set (Icons.Filled.ContentCopy for the code
|
||||||
// copy buttons); -core only ships a small subset.
|
// copy buttons); -core only ships a small subset.
|
||||||
implementation("org.jetbrains.compose.material:material-icons-extended:$composeVersion")
|
implementation("org.jetbrains.compose.material:material-icons-extended:$materialIconsVersion")
|
||||||
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:$coroutinesVersion")
|
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:$coroutinesVersion")
|
||||||
implementation("org.jetbrains.kotlinx:kotlinx-serialization-json:$serializationVersion")
|
implementation("org.jetbrains.kotlinx:kotlinx-serialization-json:$serializationVersion")
|
||||||
// OkHttp is a JVM library; both targets here are JVM-based
|
// OkHttp is a JVM library; both targets here are JVM-based
|
||||||
@@ -68,26 +82,14 @@ kotlin {
|
|||||||
// M7: EncryptedSharedPreferences for the pairing token
|
// M7: EncryptedSharedPreferences for the pairing token
|
||||||
// (docs/09 §9.7; AndroidSecureStore).
|
// (docs/09 §9.7; AndroidSecureStore).
|
||||||
implementation("androidx.security:security-crypto:1.1.0")
|
implementation("androidx.security:security-crypto:1.1.0")
|
||||||
implementation("androidx.media3:media3-exoplayer:1.3.1")
|
implementation("androidx.media3:media3-exoplayer:1.11.0")
|
||||||
implementation("androidx.media3:media3-ui:1.3.1")
|
implementation("androidx.media3:media3-ui:1.11.0")
|
||||||
// SAF picker (rememberLauncherForActivityResult).
|
// SAF picker (rememberLauncherForActivityResult).
|
||||||
implementation("androidx.activity:activity-compose:1.9.2")
|
implementation("androidx.activity:activity-compose:1.13.0")
|
||||||
// M5: FCM push (inert without a Firebase project / google-services.json;
|
// M5: FCM push (inert without a Firebase project / google-services.json;
|
||||||
// the ntfy listener is the fallback). The google-services plugin is
|
// the ntfy listener is the fallback). The google-services plugin is
|
||||||
// applied conditionally in the app module.
|
// applied conditionally in the app module.
|
||||||
implementation("com.google.firebase:firebase-messaging:23.1.2")
|
implementation("com.google.firebase:firebase-messaging:25.1.2")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
android {
|
|
||||||
namespace = "iris.shared"
|
|
||||||
compileSdk = 34
|
|
||||||
defaultConfig {
|
|
||||||
minSdk = 29
|
|
||||||
}
|
|
||||||
compileOptions {
|
|
||||||
sourceCompatibility = JavaVersion.VERSION_17
|
|
||||||
targetCompatibility = JavaVersion.VERSION_17
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -157,7 +157,9 @@ fun MarkdownText(
|
|||||||
ordered = base,
|
ordered = base,
|
||||||
bullet = base,
|
bullet = base,
|
||||||
list = base,
|
list = base,
|
||||||
link = base.copy(textDecoration = TextDecoration.Underline),
|
textLink = TextLinkStyles(
|
||||||
|
style = base.copy(textDecoration = TextDecoration.Underline).toSpanStyle(),
|
||||||
|
),
|
||||||
table = base.copy(fontSize = fontSize * 0.95f),
|
table = base.copy(fontSize = fontSize * 0.95f),
|
||||||
),
|
),
|
||||||
components = markdownComponents(
|
components = markdownComponents(
|
||||||
@@ -207,7 +209,7 @@ internal fun CodeBlockWithCopy(
|
|||||||
) {
|
) {
|
||||||
val clipboard = LocalClipboardManager.current
|
val clipboard = LocalClipboardManager.current
|
||||||
Box {
|
Box {
|
||||||
MarkdownHighlightedCode(code = code, language = language, highlights = highlights, style = style)
|
MarkdownHighlightedCode(code = code, language = language, highlightsBuilder = highlights, style = style)
|
||||||
if (code.isNotBlank()) {
|
if (code.isNotBlank()) {
|
||||||
IconButton(
|
IconButton(
|
||||||
onClick = { clipboard.setText(AnnotatedString(code)) },
|
onClick = { clipboard.setText(AnnotatedString(code)) },
|
||||||
|
|||||||
@@ -38,11 +38,11 @@ private suspend fun ensureKcefInitialized() {
|
|||||||
KCEF.init(
|
KCEF.init(
|
||||||
builder = {
|
builder = {
|
||||||
installDir(File(System.getProperty("user.home"), ".iris/kcef-bundle"))
|
installDir(File(System.getProperty("user.home"), ".iris/kcef-bundle"))
|
||||||
// Pinned to the JBR 17 release the KCEF 2024.04.20.x line was
|
// Pinned to the JBR 17 release the KCEF 2025.03.23 line is
|
||||||
// built against; the default "latest" JBR may be JDK 21-based
|
// built against; the default "latest" JBR may be JDK 21-based
|
||||||
// and is not guaranteed compatible.
|
// and is not guaranteed compatible.
|
||||||
download {
|
download {
|
||||||
github { release("jbr-release-17.0.12b1207.37") }
|
github { release("jbr-release-17.0.14b1367.22") }
|
||||||
}
|
}
|
||||||
settings {
|
settings {
|
||||||
cachePath = File(System.getProperty("user.home"), ".iris/kcef-cache").absolutePath
|
cachePath = File(System.getProperty("user.home"), ".iris/kcef-cache").absolutePath
|
||||||
|
|||||||
Reference in new issue
Block a user