diff --git a/appyx-navigation/android/build.gradle.kts b/appyx-navigation/android/build.gradle.kts index 0d9d5d5e8..8975c0f95 100644 --- a/appyx-navigation/android/build.gradle.kts +++ b/appyx-navigation/android/build.gradle.kts @@ -15,9 +15,7 @@ appyx { dependencies { val composeBom = platform(libs.compose.bom) - api(composeBom) api(libs.kotlin.coroutines.android) - api(libs.compose.ui.tooling) implementation(composeBom) @@ -26,7 +24,7 @@ dependencies { androidTestImplementation(composeBom) androidTestImplementation(libs.androidx.test.espresso.core) androidTestImplementation(libs.androidx.test.junit) - androidTestImplementation(libs.compose.ui.test.junit4) androidTestImplementation(libs.compose.foundation) + androidTestImplementation(libs.compose.ui.test.junit4) androidTestImplementation(project(":utils:testing-ui")) } diff --git a/appyx-navigation/common/build.gradle.kts b/appyx-navigation/common/build.gradle.kts index 11c5fadb6..11c1cc48c 100644 --- a/appyx-navigation/common/build.gradle.kts +++ b/appyx-navigation/common/build.gradle.kts @@ -95,7 +95,6 @@ android { androidTestImplementation(libs.androidx.test.espresso.core) androidTestImplementation(libs.androidx.test.junit) androidTestImplementation(libs.compose.ui.test.junit4) - androidTestImplementation(libs.compose.foundation) androidTestImplementation(project(":utils:testing-ui")) } } diff --git a/build.gradle.kts b/build.gradle.kts index c28ec7ce5..2703ef78c 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -30,6 +30,11 @@ dependencyAnalysis { all { onIncorrectConfiguration { severity("fail") + + exclude( + // Should be ignored as it's raised in many modules due to misconfiguration. + "org.jetbrains.kotlin:kotlin-stdlib" + ) } onUnusedDependencies { severity("fail") @@ -46,6 +51,12 @@ dependencyAnalysis { // Convenience for convention plugins to avoid needing to define this. "org.junit.jupiter:junit-jupiter-api", + // Some modules declare these dependencies but have not used them yet. + "androidx.compose.ui:ui-test-junit4", + "androidx.test.espresso:espresso-core", + "androidx.test.ext:junit", + ":utils:testing-ui", + // This is used in:demos:appyx-interactions:android. But raised as unused. "androidx.compose.material:material-icons-extended", ) @@ -65,6 +76,22 @@ dependencyAnalysis { exclude(":utils:testing-unit-common") } } + project(":utils:interop-ribs") { + onIncorrectConfiguration { + severity("fail") + exclude( + // Should be ignored, as they could potentially clash with dependencies + // from client code. + "com.github.badoo.RIBs:rib-compose", + ) + } + onUnusedDependencies { + severity("fail") + exclude( + "androidx.activity:activity-compose", + ) + } + } } } diff --git a/demos/appyx-interactions/ios/build.gradle.kts b/demos/appyx-interactions/ios/build.gradle.kts index 875ec295d..613555cb8 100644 --- a/demos/appyx-interactions/ios/build.gradle.kts +++ b/demos/appyx-interactions/ios/build.gradle.kts @@ -46,13 +46,6 @@ kotlin { } } -compose.experimental { - uikit.application { - projectName = "Appyx" - bundleIdPrefix = "com.bumble.appyx" - } -} - dependencies { add("kspIosArm64", project(":ksp:appyx-processor")) add("kspIosX64", project(":ksp:appyx-processor")) diff --git a/demos/appyx-interactions/ios/ios.podspec b/demos/appyx-interactions/ios/ios.podspec index 2e9af6c20..fd91cb885 100644 --- a/demos/appyx-interactions/ios/ios.podspec +++ b/demos/appyx-interactions/ios/ios.podspec @@ -11,6 +11,17 @@ Pod::Spec.new do |spec| spec.ios.deployment_target = '16.4' + if !Dir.exist?('build/cocoapods/framework/ios.framework') || Dir.empty?('build/cocoapods/framework/ios.framework') + raise " + + Kotlin framework 'ios' doesn't exist yet, so a proper Xcode project can't be generated. + 'pod install' should be executed after running ':generateDummyFramework' Gradle task: + + ./gradlew :demos:appyx-interactions:ios:generateDummyFramework + + Alternatively, proper pod installation is performed during Gradle sync in the IDE (if Podfile location is set)" + end + spec.pod_target_xcconfig = { 'KOTLIN_PROJECT_PATH' => ':demos:appyx-interactions:ios', 'PRODUCT_MODULE_NAME' => 'ios', diff --git a/demos/appyx-interactions/iosApp/Configuration/Config.xcconfig b/demos/appyx-interactions/iosApp/Configuration/Config.xcconfig index 59e262bd6..27d0274ee 100644 --- a/demos/appyx-interactions/iosApp/Configuration/Config.xcconfig +++ b/demos/appyx-interactions/iosApp/Configuration/Config.xcconfig @@ -1,3 +1,3 @@ TEAM_ID= -BUNDLE_ID=com.bumble.appyx.Appyx -APP_NAME=Appyx +BUNDLE_ID=com.bumble.appyx.interactions +APP_NAME=Appyx Interactions diff --git a/demos/appyx-navigation/ios/build.gradle.kts b/demos/appyx-navigation/ios/build.gradle.kts index 63d859c17..09b3f3212 100644 --- a/demos/appyx-navigation/ios/build.gradle.kts +++ b/demos/appyx-navigation/ios/build.gradle.kts @@ -45,13 +45,6 @@ kotlin { } } -compose.experimental { - uikit.application { - projectName = "Appyx" - bundleIdPrefix = "com.bumble.appyx" - } -} - tasks.register("copyResources") { // Dirs containing files we want to copy from("../common/src/commonMain/resources") diff --git a/demos/appyx-navigation/ios/ios.podspec b/demos/appyx-navigation/ios/ios.podspec index 34ceebefc..e4571c19a 100644 --- a/demos/appyx-navigation/ios/ios.podspec +++ b/demos/appyx-navigation/ios/ios.podspec @@ -11,6 +11,17 @@ Pod::Spec.new do |spec| spec.ios.deployment_target = '17.0' + if !Dir.exist?('build/cocoapods/framework/ios.framework') || Dir.empty?('build/cocoapods/framework/ios.framework') + raise " + + Kotlin framework 'ios' doesn't exist yet, so a proper Xcode project can't be generated. + 'pod install' should be executed after running ':generateDummyFramework' Gradle task: + + ./gradlew :demos:appyx-navigation:ios:generateDummyFramework + + Alternatively, proper pod installation is performed during Gradle sync in the IDE (if Podfile location is set)" + end + spec.pod_target_xcconfig = { 'KOTLIN_PROJECT_PATH' => ':demos:appyx-navigation:ios', 'PRODUCT_MODULE_NAME' => 'ios', diff --git a/demos/appyx-navigation/iosApp/Configuration/Config.xcconfig b/demos/appyx-navigation/iosApp/Configuration/Config.xcconfig index 59e262bd6..1b0573c0f 100644 --- a/demos/appyx-navigation/iosApp/Configuration/Config.xcconfig +++ b/demos/appyx-navigation/iosApp/Configuration/Config.xcconfig @@ -1,3 +1,3 @@ TEAM_ID= -BUNDLE_ID=com.bumble.appyx.Appyx -APP_NAME=Appyx +BUNDLE_ID=com.bumble.appyx.navigation +APP_NAME=Appyx Navigation diff --git a/demos/image-loader/common/build.gradle.kts b/demos/image-loader/common/build.gradle.kts index cba41bc5e..b8d70eb27 100644 --- a/demos/image-loader/common/build.gradle.kts +++ b/demos/image-loader/common/build.gradle.kts @@ -9,7 +9,7 @@ appyx { } kotlin { - android { + androidTarget { publishLibraryVariants("release") } jvm("desktop") { diff --git a/demos/navigation-compose/build.gradle.kts b/demos/navigation-compose/build.gradle.kts index e74b6aa13..bdd8b0452 100644 --- a/demos/navigation-compose/build.gradle.kts +++ b/demos/navigation-compose/build.gradle.kts @@ -14,9 +14,8 @@ appyx { dependencies { val composeBom = platform(libs.compose.bom) - api(composeBom) - api(project(":appyx-navigation:appyx-navigation")) - api(project(":appyx-components:stable:backstack:backstack")) + implementation(project(":appyx-navigation:appyx-navigation")) + implementation(project(":appyx-components:stable:backstack:backstack")) implementation(composeBom) implementation(libs.androidx.navigation.compose) diff --git a/demos/sandbox-appyx-navigation/common/build.gradle.kts b/demos/sandbox-appyx-navigation/common/build.gradle.kts index 63c711a52..ee8764d5f 100644 --- a/demos/sandbox-appyx-navigation/common/build.gradle.kts +++ b/demos/sandbox-appyx-navigation/common/build.gradle.kts @@ -11,7 +11,7 @@ appyx { } kotlin { - android { + androidTarget { publishLibraryVariants("release") } jvm("desktop") { diff --git a/demos/sandbox-appyx-navigation/ios/build.gradle.kts b/demos/sandbox-appyx-navigation/ios/build.gradle.kts index 5d55d2fdf..5541981b3 100644 --- a/demos/sandbox-appyx-navigation/ios/build.gradle.kts +++ b/demos/sandbox-appyx-navigation/ios/build.gradle.kts @@ -43,13 +43,6 @@ kotlin { } } -compose.experimental { - uikit.application { - projectName = "Appyx" - bundleIdPrefix = "com.bumble.appyx" - } -} - dependencies { add("kspIosArm64", project(":ksp:appyx-processor")) add("kspIosX64", project(":ksp:appyx-processor")) diff --git a/demos/sandbox-appyx-navigation/ios/ios.podspec b/demos/sandbox-appyx-navigation/ios/ios.podspec index db2b79a74..b9fa1fe72 100644 --- a/demos/sandbox-appyx-navigation/ios/ios.podspec +++ b/demos/sandbox-appyx-navigation/ios/ios.podspec @@ -11,6 +11,17 @@ Pod::Spec.new do |spec| spec.ios.deployment_target = '16.4' + if !Dir.exist?('build/cocoapods/framework/ios.framework') || Dir.empty?('build/cocoapods/framework/ios.framework') + raise " + + Kotlin framework 'ios' doesn't exist yet, so a proper Xcode project can't be generated. + 'pod install' should be executed after running ':generateDummyFramework' Gradle task: + + ./gradlew :demos:sandbox-appyx-navigation:ios:generateDummyFramework + + Alternatively, proper pod installation is performed during Gradle sync in the IDE (if Podfile location is set)" + end + spec.pod_target_xcconfig = { 'KOTLIN_PROJECT_PATH' => ':demos:sandbox-appyx-navigation:ios', 'PRODUCT_MODULE_NAME' => 'ios', diff --git a/demos/sandbox-appyx-navigation/iosApp/Configuration/Config.xcconfig b/demos/sandbox-appyx-navigation/iosApp/Configuration/Config.xcconfig index 59e262bd6..6c0a4f609 100644 --- a/demos/sandbox-appyx-navigation/iosApp/Configuration/Config.xcconfig +++ b/demos/sandbox-appyx-navigation/iosApp/Configuration/Config.xcconfig @@ -1,3 +1,3 @@ TEAM_ID= -BUNDLE_ID=com.bumble.appyx.Appyx -APP_NAME=Appyx +BUNDLE_ID=com.bumble.appyx.sandbox +APP_NAME=Appyx Sandbox diff --git a/gradle.properties b/gradle.properties index 3310eab5e..684ec4a74 100644 --- a/gradle.properties +++ b/gradle.properties @@ -4,6 +4,7 @@ android.nonTransitiveRClass=false android.useAndroidX=true kotlin.code.style=official kotlin.mpp.androidSourceSetLayoutVersion1.nowarn=true +kotlin.mpp.applyDefaultHierarchyTemplate=false kotlin.mpp.stability.nowarn=true kotlin.mpp.enableCInteropCommonization=true library.version=2.0.0-alpha09 diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 460b6b22d..ed1da2a99 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -2,23 +2,23 @@ [versions] accompanist = "0.28.0" -agp = "8.1.2" +agp = "8.2.1" androidCompileSdk = "34" androidMinSdk = "21" androidTargetSdk = "32" androidx-lifecycle = "2.6.1" androidx-navigation-compose = "2.5.1" coil = "2.2.1" -composePlugin = "1.5.3" +composePlugin = "1.5.11" composeBom = "2023.10.01" -composeCompiler = "1.5.3" +composeCompiler = "1.5.7" coroutines = "1.6.4" -dependencyAnalysis = "1.13.1" +dependencyAnalysis = "1.29.0" detekt = "1.21.0" junit5 = "5.8.2" jvmTarget = "11" -kotlin = "1.9.10" -ksp = "1.9.10-1.0.13" +kotlin = "1.9.21" +ksp = "1.9.21-1.0.16" mvicore = "1.2.6" ribs = "0.39.0" serialization-json = "1.5.0" @@ -55,7 +55,7 @@ compose-material3 = { module = "androidx.compose.material3:material3" } compose-material-icons-extended = { module = "androidx.compose.material:material-icons-extended" } compose-runtime = { module = "androidx.compose.runtime:runtime" } compose-ui-test-junit4 = { module = "androidx.compose.ui:ui-test-junit4" } -compose-ui-test-junit4-android = { group = "androidx.compose.ui", name = "ui-test-junit4-android", version.ref = "composeCompiler" } +compose-ui-test-junit4-android = { module = "androidx.compose.ui:ui-test-junit4-android" } compose-ui-tooling = { module = "androidx.compose.ui:ui-tooling" } compose-ui-ui = { module = "androidx.compose.ui:ui" } compose-ui-test-manifest = { module = "androidx.compose.ui:ui-test-manifest" } diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 37aef8d3f..3499ded5c 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.5-bin.zip networkTimeout=10000 zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/utils/interop-ribs/build.gradle.kts b/utils/interop-ribs/build.gradle.kts index 0a31cfddc..9697b4a74 100644 --- a/utils/interop-ribs/build.gradle.kts +++ b/utils/interop-ribs/build.gradle.kts @@ -29,7 +29,6 @@ dependencies { implementation(libs.androidx.activity.compose) androidTestImplementation(composeBom) - androidTestImplementation(libs.androidx.activity.compose) androidTestImplementation(libs.androidx.test.espresso.core) androidTestImplementation(libs.androidx.test.junit) androidTestImplementation(libs.compose.foundation.layout)