3
0
Mirror von https://github.com/PaperMC/Paper.git synchronisiert 2024-12-12 17:40:09 +01:00

Specify mainCapabilityAttribute for paper-api

Dieser Commit ist enthalten in:
Jason Penilla 2024-10-25 12:47:24 -07:00
Ursprung b711764991
Commit 2e76d3f1e2
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: 0E75A301420E48F8
2 geänderte Dateien mit 8 neuen und 4 gelöschten Zeilen

Datei anzeigen

@ -11,7 +11,7 @@ import kotlin.io.path.*
plugins { plugins {
java java
`maven-publish` `maven-publish`
id("io.papermc.paperweight.core") version "1.7.3" id("io.papermc.paperweight.core") version "1.7.4"
} }
allprojects { allprojects {

Datei anzeigen

@ -6,7 +6,7 @@ Subject: [PATCH] Brigadier based command API
Co-authored-by: Jake Potrebic <jake.m.potrebic@gmail.com> Co-authored-by: Jake Potrebic <jake.m.potrebic@gmail.com>
diff --git a/build.gradle.kts b/build.gradle.kts diff --git a/build.gradle.kts b/build.gradle.kts
index 6c8464d9e862b1b4dbf7a77e25446aa870803dae..e7c96be769fde8375b9a1b128cc7ce474144d16d 100644 index 6c8464d9e862b1b4dbf7a77e25446aa870803dae..254fd96d3950b4494c7e43547b00b5175ee53c93 100644
--- a/build.gradle.kts --- a/build.gradle.kts
+++ b/build.gradle.kts +++ b/build.gradle.kts
@@ -27,6 +27,7 @@ configurations.api { @@ -27,6 +27,7 @@ configurations.api {
@ -17,18 +17,22 @@ index 6c8464d9e862b1b4dbf7a77e25446aa870803dae..e7c96be769fde8375b9a1b128cc7ce47
// api dependencies are listed transitively to API consumers // api dependencies are listed transitively to API consumers
api("com.google.guava:guava:32.1.2-jre") api("com.google.guava:guava:32.1.2-jre")
api("com.google.code.gson:gson:2.10.1") api("com.google.code.gson:gson:2.10.1")
@@ -93,9 +94,29 @@ sourceSets { @@ -93,9 +94,33 @@ sourceSets {
} }
} }
// Paper end // Paper end
+// Paper start - brigadier API +// Paper start - brigadier API
+val outgoingVariants = arrayOf("runtimeElements", "apiElements", "sourcesElements", "javadocElements") +val outgoingVariants = arrayOf("runtimeElements", "apiElements", "sourcesElements", "javadocElements")
+val mainCapability = "${project.group}:${project.name}:${project.version}"
+configurations { +configurations {
+ val outgoing = outgoingVariants.map { named(it) } + val outgoing = outgoingVariants.map { named(it) }
+ for (config in outgoing) { + for (config in outgoing) {
+ config { + config {
+ attributes {
+ attribute(io.papermc.paperweight.util.mainCapabilityAttribute, mainCapability)
+ }
+ outgoing { + outgoing {
+ capability("${project.group}:${project.name}:${project.version}") + capability(mainCapability)
+ capability("io.papermc.paper:paper-mojangapi:${project.version}") + capability("io.papermc.paper:paper-mojangapi:${project.version}")
+ capability("com.destroystokyo.paper:paper-mojangapi:${project.version}") + capability("com.destroystokyo.paper:paper-mojangapi:${project.version}")
+ } + }