Bartosz Galek
11/25/2024, 8:01 AMephemient
11/25/2024, 8:19 AMtask.withType<...> { ... }
unfortunately causes those tasks to be eagerly configured. you want to use
task.withType<...>().configureEach { ... }
to maintain defer task configuration until it is necessary. https://docs.gradle.org/current/userguide/task_configuration_avoidance.html#sec:how_do_i_defer_configurationBartosz Galek
11/25/2024, 8:29 AMconfiguration avoidance
, convention plugins.
, platform dependencies
and some most used plugins)Bartosz Galek
11/25/2024, 8:36 AM.configureEach
would be not needed (I know changing defaults is hard), adding configureEach
seems like a big migration in larger orgizations and requires some explanation - you know "it works without it, why to add this?" 🙂Vampire
11/25/2024, 8:48 AMconfigureEach
for the 9-step, just for being able to remove them in the 10-step again if he even notices.Bartosz Galek
11/25/2024, 8:50 AMVampire
11/25/2024, 9:05 AMwrapper
task is only for writing the wrapper files, not migrating anything. And I don't think it will really work nicely, besides that I doubt they have the resources to do something like that.Bartosz Galek
11/25/2024, 9:17 AM./gradlew modernize
😉Michael Aubert
11/26/2024, 1:23 PMMichael Aubert
11/26/2024, 1:25 PMAndrey Mishchenko
11/29/2024, 2:39 AMVampire
11/29/2024, 3:50 AMAndrey Mishchenko
11/29/2024, 4:19 AMVampire
11/29/2024, 7:38 AM.all
and deprecate that method.Aurimas Liutikas
12/19/2024, 4:55 PM.withType
without configure each, .all
calls, and a dozen others, my team ships a set of Lint checks you can apply to your Gradle plugin project
https://developer.android.com/jetpack/androidx/releases/lint
It's called android lint but it runs on JVM projects just fine