v0.18
Kotlin Gradle Plugin and Android Gradle Plugin removed from transitive dependencies
⚠️ BREAKING CHANGE!
It should be simple to change KGP and APG versions, no matter what versions were used on gradle-infrastructure compilation. Previously it was hard to update gradle-infrastructure without updating AGP and KGP, and also it was hard to downgrade AGP or KGP if it was needed.
Since now, KGP and AGP removed from transitive dependencies, and you should add it to your project manually. You can use two different approaches to do it:
-
Add AGP and KGP to top-level
build.gradle.kts
withapply false
// (root)/build.gradle.kts plugins { // Use `apply false` in the top-level build.gradle file to add a Gradle // plugin as a build dependency but not apply it to the current (root) project. // Here you can specify desired AGP and KGP versions to use. id("com.android.application") version "7.4.2" apply false id("org.jetbrains.kotlin.android") version "1.8.10" apply false }
-
If you have
buildSrc
or some other module containing build logic, you can add AGP and KGP todependencies
of this module:// (root)/buildSrc/build.gradle.kts dependencies { // Here you can specify desired AGP and KGP versions to use. implementation(kotlin("gradle-plugin", version = "1.8.10")) implementation("com.android.tools.build:gradle:7.4.2") }
Minimal required AGP and KGP will always be specified in README.
BREAKING CHANGES
- android: Fixed obfuscation on QA builds with AGP 7.2+ (#120)
- android: Default
targetSdk
changed from32
to33
- android: Don't set
targetSdk
in library modules. This field is deprecated and doesn't take any effect since AGP 7.4 (b/230625468) - android: Removed default
resourceConfigurations
. UseresourceConfigurations.add("ru")
if you want to keep old behavior (#115) - Change default target JVM from 1.8 to 11 (property
redmadrobot.jvmTarget
)
Other changes
- android: Removed workaround for b/215407138 that is fixed in AGP 7.4
- publish: More detailed description for the case when plugin cannot recognize project type (#116)
- Update Gradle to 8.0.2
Dependencies
infrastructure-kotlin:
- Kotlin
1.7.10
→1.8.10
infrastructure-android:
- Android Gradle Plugin
7.2.1
→7.4.2
(:warning: Minimal required AGP version is7.4.0
) - Android cache fix Gradle plugin
2.5.6
→2.7.0
infrastructure-detekt:
Full Changelog: v0.17...v0.18