generated from Polyfrost/OneConfigExampleMod
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
54 additions
and
184 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,7 @@ | ||
plugins { | ||
kotlin("jvm") version "1.9.10" apply false | ||
id("org.polyfrost.multi-version.root") | ||
id("com.github.johnrengelman.shadow") version "8.1.1" apply false | ||
id("dev.deftu.gradle.multiversion-root") | ||
} | ||
|
||
preprocess { | ||
"1.12.2-forge"(11202, "srg") { | ||
"1.8.9-forge"(10809, "srg") | ||
} | ||
"1.8.9-forge"(10809, "srg") {} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,43 @@ | ||
@file:Suppress("PropertyName") | ||
import groovy.lang.MissingPropertyException | ||
|
||
pluginManagement { | ||
repositories { | ||
// Repositories | ||
maven("https://maven.deftu.dev/releases") | ||
maven("https://maven.fabricmc.net") | ||
maven("https://maven.architectury.dev/") | ||
maven("https://maven.minecraftforge.net") | ||
maven("https://repo.essential.gg/repository/maven-public") | ||
maven("https://server.bbkr.space/artifactory/libs-release/") | ||
maven("https://jitpack.io/") | ||
|
||
// Snapshots | ||
maven("https://maven.deftu.dev/snapshots") | ||
mavenLocal() | ||
|
||
// Default repositories | ||
gradlePluginPortal() | ||
mavenCentral() | ||
maven("https://repo.polyfrost.org/releases") // Adds the Polyfrost maven repository to get Polyfrost Gradle Toolkit | ||
} | ||
|
||
plugins { | ||
val pgtVersion = "0.6.6" // Sets the default versions for Polyfrost Gradle Toolkit | ||
id("org.polyfrost.multi-version.root") version pgtVersion | ||
kotlin("jvm") version("2.0.0") | ||
id("dev.deftu.gradle.multiversion-root") version("2.11.1") | ||
} | ||
} | ||
|
||
val mod_name: String by settings | ||
|
||
// Configures the root project Gradle name based on the value in `gradle.properties` | ||
rootProject.name = mod_name | ||
val projectName: String = extra["mod.name"]?.toString() | ||
?: throw MissingPropertyException("mod.name has not been set.") | ||
rootProject.name = projectName | ||
rootProject.buildFileName = "root.gradle.kts" | ||
|
||
// Adds all of our build target versions to the classpath if we need to add version-specific code. | ||
listOf( | ||
"1.8.9-forge", // Update this if you want to remove/add a version, along with `build.gradle.kts` and `root.gradle.kts`. | ||
//"1.12.2-forge" // uncomment if you want 1.12.2 support in your mod | ||
"1.8.9-forge" | ||
).forEach { version -> | ||
include(":$version") | ||
project(":$version").apply { | ||
projectDir = file("versions/$version") | ||
buildFileName = "../../build.gradle.kts" | ||
} | ||
} | ||
} |