forked from jellyfin/jellyfin-android
-
Notifications
You must be signed in to change notification settings - Fork 0
/
settings.gradle.kts
33 lines (28 loc) · 1007 Bytes
/
settings.gradle.kts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
import java.util.Properties
include(":app")
pluginManagement {
val kotlinVersion: String by settings
resolutionStrategy {
eachPlugin {
if (requested.id.namespace?.startsWith("org.jetbrains.kotlin") == true)
useVersion(kotlinVersion)
}
}
}
// Load properties from local.properties
val properties = Properties().apply {
val location = File("local.properties")
if (location.exists())
load(location.inputStream())
}
// Get value for dependency substitution
val enableDependencySubstitution = properties.getProperty("enable.dependency.substitution", "true").equals("true", true)
// Replace apiclient dependency with local version
val apiclientLocation = "../jellyfin-apiclient-java"
if (File(apiclientLocation).exists() && enableDependencySubstitution) {
includeBuild(apiclientLocation) {
dependencySubstitution {
substitute(module("org.jellyfin.apiclient:android")).with(project(":android"))
}
}
}