mirror of https://github.com/PaperMC/Paper.git
68 lines
2.3 KiB
Diff
68 lines
2.3 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Jason Penilla <11360596+jpenilla@users.noreply.github.com>
|
|
Date: Tue, 28 Nov 2023 19:28:45 -0700
|
|
Subject: [PATCH] MergedProperties POC
|
|
|
|
|
|
diff --git a/build.gradle.kts b/build.gradle.kts
|
|
index e827ee211e3c65dc68ac5867fd8476639df63645..7456c41ccf126790ec11652d244710e2b797f237 100644
|
|
--- a/build.gradle.kts
|
|
+++ b/build.gradle.kts
|
|
@@ -1,3 +1,5 @@
|
|
+import io.papermc.paperweight.util.MergedProperties
|
|
+
|
|
plugins {
|
|
`java-library`
|
|
`maven-publish`
|
|
@@ -9,11 +11,13 @@ java {
|
|
withJavadocJar()
|
|
}
|
|
|
|
-val annotationsVersion = "24.0.1"
|
|
-val bungeeCordChatVersion = "1.20-R0.1"
|
|
-val adventureVersion = "4.14.0"
|
|
-val slf4jVersion = "1.8.0-beta4"
|
|
-val log4jVersion = "2.17.1"
|
|
+val versions = MergedProperties.fromAllProjects(project, "versions.properties")
|
|
+val annotationsVersion by versions
|
|
+val bungeeCordChatVersion by versions
|
|
+val adventureVersion by versions
|
|
+val slf4jVersion by versions
|
|
+val log4jVersion by versions
|
|
+val asmVersion by versions
|
|
val apiAndDocs: Configuration by configurations.creating {
|
|
attributes {
|
|
attribute(Category.CATEGORY_ATTRIBUTE, objects.named(Category.DOCUMENTATION))
|
|
@@ -48,8 +52,8 @@ dependencies {
|
|
api("org.apache.logging.log4j:log4j-api:$log4jVersion")
|
|
api("org.slf4j:slf4j-api:$slf4jVersion")
|
|
|
|
- implementation("org.ow2.asm:asm:9.4")
|
|
- implementation("org.ow2.asm:asm-commons:9.4")
|
|
+ implementation("org.ow2.asm:asm:$asmVersion")
|
|
+ implementation("org.ow2.asm:asm-commons:$asmVersion")
|
|
// Paper end
|
|
|
|
api("org.apache.maven:maven-resolver-provider:3.8.5")
|
|
@@ -71,7 +75,7 @@ dependencies {
|
|
testImplementation("org.junit.jupiter:junit-jupiter:5.10.0")
|
|
testImplementation("org.hamcrest:hamcrest:2.2")
|
|
testImplementation("org.mockito:mockito-core:5.5.0")
|
|
- testImplementation("org.ow2.asm:asm-tree:9.5")
|
|
+ testImplementation("org.ow2.asm:asm-tree:$asmVersion")
|
|
}
|
|
|
|
// Paper start
|
|
diff --git a/versions.properties b/versions.properties
|
|
new file mode 100644
|
|
index 0000000000000000000000000000000000000000..4e284ef8c083571a6655c9beeaaa20bd554b8395
|
|
--- /dev/null
|
|
+++ b/versions.properties
|
|
@@ -0,0 +1,6 @@
|
|
+annotationsVersion = 24.0.1
|
|
+bungeeCordChatVersion = 1.20-R0.1
|
|
+adventureVersion = 4.14.0
|
|
+slf4jVersion = 1.8.0-beta4
|
|
+log4jVersion = 2.17.1
|
|
+asmVersion = 9.6
|