mirror of
https://github.com/ankidroid/Anki-Android.git
synced 2024-09-19 19:42:17 +02:00
6b65c45386
See https://docs.gradle.org/current/userguide/plugins.html#sec:plugins_block The plugins that are to be used in different modules are added in the top level build file with apply "false"(doesn't make sense to apply them on the root project). Then the project modules, from the plugins already available on the classpath, actually apply the ones they need. Ktlint plugin was applied directly to all subprojects(initially it was added through allprojects {} but it doesn't make sense to add it to the root project as it doesn't contain source code, so subprojects{} was used instead). The amazonappstorepublisher plugin also required some custom configuration as we need the latest versions which are not available in mavenCentral() but can be fetched from jitpack.io.
19 lines
600 B
Plaintext
19 lines
600 B
Plaintext
pluginManagement {
|
|
repositories {
|
|
google()
|
|
gradlePluginPortal()
|
|
mavenCentral()
|
|
maven(url = "https://jitpack.io") // only needed for the "amazonappstorepublisher" plugin
|
|
}
|
|
resolutionStrategy {
|
|
// TODO try to find another plugin for this functionality?
|
|
eachPlugin {
|
|
if (requested.id.id == "app.brant.amazonappstorepublisher") {
|
|
useModule("com.github.BrantApps.gradle-amazon-app-store-publisher:amazonappstorepublisher:master-SNAPSHOT")
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
include(":lint-rules", ":api", ":AnkiDroid")
|