2022-11-14 10:36:50 +03:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
|
|
|
|
2018-10-23 21:20:28 +03:00
|
|
|
pluginManagement {
|
2024-08-19 18:24:50 +03:00
|
|
|
if (!gradle.hasProperty("mozconfig")){
|
|
|
|
apply from: file('../gradle/mozconfig.gradle')
|
|
|
|
}
|
2024-01-18 17:38:47 +03:00
|
|
|
|
|
|
|
repositories {
|
|
|
|
gradle.mozconfig.substs.GRADLE_MAVEN_REPOSITORIES.each { repository ->
|
|
|
|
maven {
|
|
|
|
url repository
|
|
|
|
if (gradle.mozconfig.substs.ALLOW_INSECURE_GRADLE_REPOSITORIES) {
|
|
|
|
allowInsecureProtocol = true
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2022-11-14 10:36:50 +03:00
|
|
|
includeBuild("../android-components/plugins/publicsuffixlist")
|
|
|
|
includeBuild("../android-components/plugins/dependencies")
|
2023-06-07 18:59:08 +03:00
|
|
|
includeBuild("../android-components/plugins/config")
|
2023-06-08 20:43:43 +03:00
|
|
|
includeBuild("./plugins/focusdependencies")
|
2022-11-14 10:36:50 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
plugins {
|
2023-06-07 18:59:08 +03:00
|
|
|
id "mozac.ConfigPlugin"
|
2022-11-14 10:36:50 +03:00
|
|
|
id 'mozac.DependenciesPlugin'
|
2023-06-08 20:43:43 +03:00
|
|
|
id 'FocusDependenciesPlugin'
|
2022-11-14 10:36:50 +03:00
|
|
|
}
|
|
|
|
|
2023-12-08 00:19:37 +03:00
|
|
|
ext.topsrcdir = rootProject.projectDir.absolutePath.minus("mobile/android/focus-android")
|
|
|
|
|
2023-03-31 00:25:28 +03:00
|
|
|
apply from: file('../shared-settings.gradle')
|
2024-05-10 09:21:28 +03:00
|
|
|
apply from: file('../autopublish-settings.gradle')
|
2023-03-31 00:25:28 +03:00
|
|
|
|
2021-04-20 08:31:42 +03:00
|
|
|
include ':app'
|
2021-07-13 17:47:44 +03:00
|
|
|
|
2022-11-14 10:36:50 +03:00
|
|
|
gradle.projectsLoaded { ->
|
2022-12-13 22:24:50 +03:00
|
|
|
// Disables A-C tests and lint when building Focus.
|
2022-11-14 10:36:50 +03:00
|
|
|
gradle.allprojects { project ->
|
|
|
|
if (project.projectDir.absolutePath.contains("/android-components/")) {
|
2023-08-23 14:40:01 +03:00
|
|
|
project.tasks.withType(Test).configureEach {
|
2022-11-14 10:36:50 +03:00
|
|
|
enabled = false
|
|
|
|
}
|
2023-08-23 14:40:01 +03:00
|
|
|
project.tasks.configureEach { task ->
|
2022-12-13 22:24:50 +03:00
|
|
|
if (task.name.contains("lint")) {
|
|
|
|
task.enabled = false
|
|
|
|
}
|
|
|
|
}
|
2022-11-14 10:36:50 +03:00
|
|
|
}
|
2022-10-24 14:48:09 +03:00
|
|
|
}
|
2021-07-13 17:47:44 +03:00
|
|
|
}
|
2024-05-10 09:21:28 +03:00
|
|
|
|
|
|
|
def projectLocalProperties = file("local.properties").with { localPropertiesFile ->
|
|
|
|
def localProperties = new Properties()
|
|
|
|
if (localPropertiesFile.canRead()) {
|
|
|
|
localPropertiesFile.withInputStream { localProperties.load(it) }
|
|
|
|
}
|
|
|
|
localProperties
|
|
|
|
}
|
|
|
|
projectLocalProperties.each { prop ->
|
|
|
|
gradle.ext."localProperties.${prop.key}" = prop.value
|
|
|
|
}
|