Skip to content

Commit 6392c48

Browse files
committed
Updated settings.gradle.kts
1 parent 11f0026 commit 6392c48

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

settings.gradle.kts

+9-4
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,8 @@ pluginManagement {
22
repositories { mavenLocal(); mavenCentral(); google(); gradlePluginPortal() }
33
}
44

5-
// @TODO: Why can't we just use libs here? We can't even use a TOML parser since it is gradle internal, and we cannot load a library in a reasonably way here.
6-
plugins {
7-
val libsTomlFile = File("gradle/libs.versions.toml").readText()
5+
buildscript {
6+
val libsTomlFile = File(this.sourceFile?.parentFile, "gradle/libs.versions.toml").readText()
87
var plugins = false
98
var version = ""
109
for (line in libsTomlFile.lines().map { it.trim() }) {
@@ -14,5 +13,11 @@ plugins {
1413
}
1514
if (version.isEmpty()) error("Can't find korge version in $libsTomlFile")
1615

17-
id("com.soywiz.korge.settings") version version
16+
repositories { mavenLocal(); mavenCentral(); google(); gradlePluginPortal() }
17+
18+
dependencies {
19+
classpath("com.soywiz.korge.settings:com.soywiz.korge.settings.gradle.plugin:$version")
20+
}
1821
}
22+
23+
apply(plugin = "com.soywiz.korge.settings")

0 commit comments

Comments
 (0)