2023-03-24 16:06:48 +01:00
|
|
|
import java.util.Locale
|
|
|
|
|
2021-06-12 14:09:34 +02:00
|
|
|
pluginManagement {
|
|
|
|
repositories {
|
|
|
|
gradlePluginPortal()
|
2022-12-13 22:27:38 +01:00
|
|
|
maven("https://repo.papermc.io/repository/maven-public/")
|
2021-06-12 14:09:34 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2023-04-01 03:26:08 +02:00
|
|
|
plugins {
|
2024-04-12 02:03:29 +02:00
|
|
|
id("org.gradle.toolchains.foojay-resolver-convention") version "0.8.0"
|
2023-04-01 03:26:08 +02:00
|
|
|
}
|
|
|
|
|
2023-04-20 17:28:39 +02:00
|
|
|
if (!file(".git").exists()) {
|
|
|
|
val errorText = """
|
|
|
|
|
|
|
|
=====================[ ERROR ]=====================
|
|
|
|
The Folia project directory is not a properly cloned Git repository.
|
|
|
|
|
|
|
|
In order to build Folia from source you must clone
|
|
|
|
the Folia repository using Git, not download a code
|
|
|
|
zip from GitHub.
|
|
|
|
|
|
|
|
See https://github.com/PaperMC/Paper/blob/master/CONTRIBUTING.md
|
|
|
|
for further information on building and modifying Paper and Forks.
|
|
|
|
===================================================
|
|
|
|
""".trimIndent()
|
|
|
|
error(errorText)
|
|
|
|
}
|
|
|
|
|
2023-03-23 12:53:58 +01:00
|
|
|
rootProject.name = "folia"
|
2021-06-12 14:09:34 +02:00
|
|
|
|
2023-03-24 16:06:48 +01:00
|
|
|
for (name in listOf("Folia-API", "Folia-Server")) {
|
|
|
|
val projName = name.lowercase(Locale.ENGLISH)
|
|
|
|
include(projName)
|
|
|
|
findProject(":$projName")!!.projectDir = file(name)
|
|
|
|
}
|