153 lines
7.6 KiB
Diff
153 lines
7.6 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: lexikiq <noellekiq@gmail.com>
|
|
Date: Thu, 24 Jun 2021 02:16:25 -0400
|
|
Subject: [PATCH] Build changes
|
|
|
|
|
|
diff --git a/build.gradle.kts b/build.gradle.kts
|
|
index 4998aff0b7cb084dcda15c6a18bbe45e99b6000a..34f1acc44c17b53d93b750a35817131145db454f 100644
|
|
--- a/build.gradle.kts
|
|
+++ b/build.gradle.kts
|
|
@@ -1,6 +1,8 @@
|
|
import io.papermc.paperweight.util.*
|
|
import java.time.Instant
|
|
|
|
+val edenVersion: String by project // Parchment
|
|
+
|
|
plugins {
|
|
java
|
|
`maven-publish`
|
|
@@ -13,7 +15,9 @@ configurations.named(log4jPlugins.compileClasspathConfigurationName) {
|
|
val alsoShade: Configuration by configurations.creating
|
|
|
|
dependencies {
|
|
- implementation(project(":paper-api"))
|
|
+ // Parchment start
|
|
+ implementation(project(":parchment-api"))
|
|
+ // Parchment end
|
|
// Paper start
|
|
implementation("org.jline:jline-terminal-jansi:3.21.0")
|
|
implementation("net.minecrell:terminalconsoleappender:1.3.0")
|
|
@@ -80,14 +84,14 @@ tasks.jar {
|
|
val gitBranch = git("rev-parse", "--abbrev-ref", "HEAD").getText().trim() // Paper
|
|
attributes(
|
|
"Main-Class" to "org.bukkit.craftbukkit.Main",
|
|
- "Implementation-Title" to "Paper",
|
|
+ "Implementation-Title" to "Parchment",
|
|
"Implementation-Version" to implementationVersion,
|
|
"Implementation-Vendor" to date, // Paper
|
|
- "Specification-Title" to "Paper",
|
|
+ "Specification-Title" to "Parchment",
|
|
"Specification-Version" to project.version,
|
|
- "Specification-Vendor" to "Paper Team",
|
|
- "Brand-Id" to "papermc:paper",
|
|
- "Brand-Name" to "Paper",
|
|
+ "Specification-Vendor" to "Project Eden",
|
|
+ "Brand-Id" to "projectedengg:parchment",
|
|
+ "Brand-Name" to "Parchment",
|
|
"Build-Number" to (build ?: ""),
|
|
"Build-Time" to Instant.now().toString(),
|
|
"Git-Branch" to gitBranch, // Paper
|
|
@@ -108,6 +112,27 @@ tasks.compileTestJava {
|
|
|
|
publishing {
|
|
publications.create<MavenPublication>("maven") {
|
|
+ // Parchment start
|
|
+ artifact(tasks.jar)
|
|
+ groupId = project.group as String?
|
|
+ artifactId = "parchment"
|
|
+ version = project.version as String?
|
|
+
|
|
+ pom {
|
|
+ name.set(project.name)
|
|
+ description.set("Minecraft server software forked from Paper")
|
|
+ }
|
|
+ }
|
|
+
|
|
+ repositories {
|
|
+ maven {
|
|
+ credentials {
|
|
+ username = properties["edenusr"] as String?
|
|
+ password = properties["edenpwd"] as String?
|
|
+ }
|
|
+ url = uri("https://sonatype.projecteden.gg/repository/maven-snapshots/")
|
|
+ }
|
|
+ // Parchment end
|
|
}
|
|
}
|
|
|
|
@@ -144,7 +169,7 @@ fun TaskContainer.registerRunTask(
|
|
name: String,
|
|
block: JavaExec.() -> Unit
|
|
): TaskProvider<JavaExec> = register<JavaExec>(name) {
|
|
- group = "paper"
|
|
+ group = "paperweight" // Parchment
|
|
mainClass.set("org.bukkit.craftbukkit.Main")
|
|
standardInput = System.`in`
|
|
workingDir = rootProject.layout.projectDirectory
|
|
diff --git a/src/main/java/com/destroystokyo/paper/Metrics.java b/src/main/java/com/destroystokyo/paper/Metrics.java
|
|
index 4b002e8b75d117b726b0de274a76d3596fce015b..4dca3956a76a9d57b3167f73696cf5d55d84606c 100644
|
|
--- a/src/main/java/com/destroystokyo/paper/Metrics.java
|
|
+++ b/src/main/java/com/destroystokyo/paper/Metrics.java
|
|
@@ -73,7 +73,7 @@ public class Metrics {
|
|
Metrics.logger = logger;
|
|
|
|
// Start submitting the data
|
|
- startSubmitting();
|
|
+ // startSubmitting(); // Parchment
|
|
}
|
|
|
|
/**
|
|
diff --git a/src/main/java/com/destroystokyo/paper/PaperVersionFetcher.java b/src/main/java/com/destroystokyo/paper/PaperVersionFetcher.java
|
|
index 532306cacd52579cdf37e4aca25887b1ed3ba6a1..87db580c74d20714e2ebe01df23811c79d1f8331 100644
|
|
--- a/src/main/java/com/destroystokyo/paper/PaperVersionFetcher.java
|
|
+++ b/src/main/java/com/destroystokyo/paper/PaperVersionFetcher.java
|
|
@@ -49,7 +49,7 @@ public class PaperVersionFetcher implements VersionFetcher {
|
|
if (build.buildNumber().isEmpty() && build.gitCommit().isEmpty()) {
|
|
updateMessage = text("You are running a development version without access to version information", color(0xFF5300));
|
|
} else {
|
|
- updateMessage = getUpdateStatusMessage("PaperMC/Paper", build);
|
|
+ updateMessage = getUpdateStatusMessage("ProjectEdenGG/Parchment", build);
|
|
}
|
|
final @Nullable Component history = this.getHistory();
|
|
|
|
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
|
|
index e02102280ed1dc300191d19bbca8f00e17701753..9b5d9729288ac11d21365c900a3b2af454c765dc 100644
|
|
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
|
|
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
|
|
@@ -303,7 +303,7 @@ public class Main {
|
|
if (buildDate.before(deadline.getTime())) {
|
|
// Paper start - This is some stupid bullshit
|
|
System.err.println("*** Warning, you've not updated in a while! ***");
|
|
- System.err.println("*** Please download a new build as per instructions from https://papermc.io/downloads/paper ***"); // Paper
|
|
+ System.err.println("*** Please download a new build as per instructions from https://github.com/ProjectEdenGG/Parchment ***"); // Paper
|
|
//System.err.println("*** Server will start in 20 seconds ***");
|
|
//Thread.sleep(TimeUnit.SECONDS.toMillis(20));
|
|
// Paper end
|
|
diff --git a/src/main/java/org/bukkit/craftbukkit/util/Versioning.java b/src/main/java/org/bukkit/craftbukkit/util/Versioning.java
|
|
index 774556a62eb240da42e84db4502e2ed43495be17..6f1b3fa6ebeabc7596034663ed06686fd3892267 100644
|
|
--- a/src/main/java/org/bukkit/craftbukkit/util/Versioning.java
|
|
+++ b/src/main/java/org/bukkit/craftbukkit/util/Versioning.java
|
|
@@ -11,7 +11,7 @@ public final class Versioning {
|
|
public static String getBukkitVersion() {
|
|
String result = "Unknown-Version";
|
|
|
|
- InputStream stream = Bukkit.class.getClassLoader().getResourceAsStream("META-INF/maven/io.papermc.paper/paper-api/pom.properties");
|
|
+ InputStream stream = Bukkit.class.getClassLoader().getResourceAsStream("META-INF/maven/gg.projecteden.parchment/parchment-api/pom.properties");
|
|
Properties properties = new Properties();
|
|
|
|
if (stream != null) {
|
|
diff --git a/src/main/java/org/spigotmc/WatchdogThread.java b/src/main/java/org/spigotmc/WatchdogThread.java
|
|
index 6db566e3111ec08a99aa429624979cb83a85e272..d3a5867e9202d1f34e66c4e6d3842211c40a6255 100644
|
|
--- a/src/main/java/org/spigotmc/WatchdogThread.java
|
|
+++ b/src/main/java/org/spigotmc/WatchdogThread.java
|
|
@@ -162,7 +162,7 @@ public final class WatchdogThread extends io.papermc.paper.util.TickThread // Pa
|
|
log.log( Level.SEVERE, "\t If this is the case, consider increasing timeout-time in spigot.yml but note that this will replace the crash with LARGE lag spikes" );
|
|
log.log( Level.SEVERE, "If you are unsure or still think this is a Paper bug, please report this to https://github.com/PaperMC/Paper/issues" );
|
|
log.log( Level.SEVERE, "Be sure to include ALL relevant console errors and Minecraft crash reports" );
|
|
- log.log( Level.SEVERE, "Paper version: " + Bukkit.getServer().getVersion() );
|
|
+ log.log( Level.SEVERE, "Parchment version: " + Bukkit.getServer().getVersion() );
|
|
//
|
|
if ( net.minecraft.world.level.Level.lastPhysicsProblem != null )
|
|
{
|