-
-
Notifications
You must be signed in to change notification settings - Fork 31
Expand file tree
/
Copy pathsettings.gradle.kts
More file actions
90 lines (85 loc) · 3.57 KB
/
Copy pathsettings.gradle.kts
File metadata and controls
90 lines (85 loc) · 3.57 KB
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
pluginManagement {
repositories {
google {
content {
includeGroupByRegex("com\\.android.*")
includeGroupByRegex("com\\.google.*")
includeGroupByRegex("androidx.*")
}
}
mavenCentral()
gradlePluginPortal()
}
}
plugins {
id("org.gradle.toolchains.foojay-resolver-convention") version "1.0.0"
}
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
google()
mavenCentral()
maven("https://jitpack.io")
}
}
buildCache {
local {
isEnabled = true
}
}
// Local cross-repo development: set `thorExtensionApiDir` in a Gradle properties file
// (for example ~/.gradle/gradle.properties) or pass it with -PthorExtensionApiDir=... to point at a
// local thor-extension-api checkout and build against its source without publishing.
// Note: this is read via providers.gradleProperty(...), so local.properties is NOT consulted.
// Leave it unset to use the pinned published version.
//
// The included build's Gradle project is named `:extension-api`, but it publishes the artifact
// `thor-extension-api`. Gradle's automatic substitution matches on the project name, so it would
// look for `:extension-api` and miss the `:thor-extension-api` dependency. We therefore map it
// explicitly via dependencySubstitution.
val thorExtensionApiDir = providers.gradleProperty("thorExtensionApiDir").orNull
if (thorExtensionApiDir != null) {
includeBuild(thorExtensionApiDir) {
dependencySubstitution {
substitute(module("com.trinadhthatakula:thor-extension-api"))
.using(project(":extension-api"))
}
}
}
// Local cross-repo development against the Asgard UI library. Set `asgardDir` to a local Asgard
// checkout (via -PasgardDir=... or a Gradle properties file — local.properties is NOT consulted) to
// build against its source without publishing; unset to use the pinned published version.
//
// Asgard is a Kotlin Multiplatform build: its `:asgard` project publishes the
// `com.trinadhthatakula:asgard` coordinate through vanniktech, but Gradle's automatic composite
// substitution keys off project identity (group), which isn't set to the publishing group — so the
// automatic mapping silently misses and the pinned Maven artifact wins. We therefore map it
// explicitly via dependencySubstitution, exactly like thor-extension-api above.
val asgardDir = providers.gradleProperty("asgardDir").orNull
if (asgardDir != null) {
includeBuild(asgardDir) {
dependencySubstitution {
substitute(module("com.trinadhthatakula:asgard"))
.using(project(":asgard"))
}
}
}
// Local cross-repo development against the Odin root-shell library (the former in-tree :suCore).
// Set `odinDir` to a local Odin checkout (via -PodinDir=... or a Gradle properties file —
// local.properties is NOT consulted) to build against its source without publishing; unset to use
// the pinned published `com.trinadhthatakula:odin` version. Odin's Gradle project is `:odin` and it
// publishes the `odin` artifact, so we map it explicitly via dependencySubstitution (same pattern as
// thor-extension-api / asgard above).
val odinDir = providers.gradleProperty("odinDir").orNull
if (odinDir != null) {
includeBuild(odinDir) {
dependencySubstitution {
substitute(module("com.trinadhthatakula:odin"))
.using(project(":odin"))
}
}
}
rootProject.name = "Thor"
include(":app")
include(":bypass")
include(":vm-runtime")