forked from h0tk3y/better-parse
-
Notifications
You must be signed in to change notification settings - Fork 2
/
settings.gradle.kts
35 lines (27 loc) · 1.19 KB
/
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
34
35
@file:Suppress("UnstableApiUsage")
import org.gradle.api.artifacts.dsl.RepositoryHandler
pluginManagement {
abstract class RepositorySetup :
BuildServiceParameters, (RepositoryHandler, Boolean) -> Unit, BuildService<RepositorySetup> {
override fun invoke(repositories: RepositoryHandler, isPlugins: Boolean): Unit = with(repositories) {
mavenCentral()
if (isPlugins) {
gradlePluginPortal()
}
}
}
val configureRepositories = gradle.sharedServices.registerIfAbsent("repositories", RepositorySetup::class) { }.get()
configureRepositories(repositories, true)
gradle.allprojects { configureRepositories(repositories, false) }
apply(from = "versions.settings.gradle.kts")
val kotlinVersion: String by settings
val benchmarkVersion: String by settings
plugins {
kotlin("multiplatform").version(kotlinVersion)
kotlin("js").version(kotlinVersion)
kotlin("plugin.allopen").version(kotlinVersion)
id("org.jetbrains.kotlinx.benchmark").version(benchmarkVersion)
}
}
rootProject.name = "better-parse"
include(":benchmarks", ":demo:demo-jvm", ":demo:demo-js", ":demo:demo-native")