Compare commits

...
Author SHA1 Message Date
renovate[bot] b6296c2e93 chore(deps): Update dependency org.spongepowered:spongeapi to v7.4.0 2024-06-20 05:37:16 +00:00
Jason Penilla 8c66bcd408 Update dependencies for Minecraft 1.21 2024-06-19 22:36:15 -07:00
Jason Penilla 2d47e73d3b Fix mc versions metadata 2024-06-02 00:27:42 -07:00
Jason Penilla f500c9fb8f 2.1.2-SNAPSHOT 2024-06-02 00:21:17 -07:00
Jason Penilla 922079cc7d release: Version 2.1.1 2024-06-02 00:17:52 -07:00
renovate[bot] 798946390b chore(deps): Update gradle and github actions 2024-06-01 20:55:47 -07:00
renovate[bot] 743a149f3b chore(deps): Update dependency org.checkerframework:checker-qual to v3.43.0 2024-06-01 20:54:59 -07:00
renovate[bot] 316945b30f chore(deps): Update dependency net.fabricmc.fabric-api:fabric-api to v0.99.4+1.20.6 2024-06-01 20:54:50 -07:00
renovate[bot] c8bf42463c chore(deps): Update adventurePlatform to v4.3.3 2024-06-01 20:54:41 -07:00
Jason Penilla a9bf505028 Update dependencies 2024-05-10 17:41:09 -07:00
Jason Penilla 60bfb21444 Opt-out of remapping on Paper 1.20.5+ 2024-05-02 14:35:06 -07:00
Jason Penilla fb13022642 feat(fabric): Initial 1.20.6 update 2024-04-29 21:45:58 -07:00
Jason Penilla 1bbf3abd9a build updates 2024-04-29 21:32:37 -07:00
renovate[bot] 1967d9802f chore(deps): Update dependency net.fabricmc:fabric-loader to v0.15.10 2024-04-29 21:25:12 -07:00
renovate[bot] 6b3d7aeab6 chore(deps): Update dependency me.modmuss50:mod-publish-plugin to v0.5.1 2024-02-26 22:12:54 -07:00
renovate[bot] 267c0426fe chore(deps): Update dependency net.kyori:adventure-bom to v4.16.0 2024-02-26 22:12:43 -07:00
renovate[bot] c3d5afa680 chore(deps): Update dependency net.kyori:adventure-platform-fabric to v5.12.0 2024-02-26 22:12:13 -07:00
renovate[bot] 2009684fb5 chore(deps): Update dependency org.junit.jupiter:junit-jupiter-engine to v5.10.2 2024-02-05 18:23:42 -07:00
renovate[bot] 56202f3f26 chore(deps): Update dependency io.papermc:hangar-publish-plugin to v0.1.2 2024-02-02 16:45:09 -07:00
renovate[bot] f2be2062e5 chore(deps): Update dependency net.kyori:adventure-platform-fabric to v5.11.0 2024-01-21 10:19:46 -07:00
Jason Penilla 4cbe7d4bf9 Use adventure textOfChildren method 2024-01-13 21:03:33 -07:00
renovate[bot] fd20b5e583 chore(deps): Update dependency io.github.waterfallmc:waterfall-api to v1.16-R0.5-SNAPSHOT 2024-01-13 20:29:52 -07:00
Jason Penilla e495e76a2d 2.1.1-SNAPSHOT 2024-01-13 20:17:46 -07:00
18 changed files with 54 additions and 92 deletions

No files matched your search

+1
View File
@@ -17,3 +17,4 @@ jobs:
modrinth-publish: true
hangar-publish: true
loom: true
jdk-version: 21
@@ -29,7 +29,6 @@ import net.kyori.adventure.text.Component;
import net.kyori.adventure.text.minimessage.MiniMessage;
import org.checkerframework.checker.nullness.qual.NonNull;
import org.checkerframework.framework.qual.DefaultQualifier;
import xyz.jpenilla.minimotd.common.util.Components;
import static net.kyori.adventure.text.Component.space;
import static net.kyori.adventure.text.Component.text;
@@ -77,7 +76,7 @@ public final class CommandHandler {
this.miniMOTD.reload();
} catch (final Exception ex) {
this.miniMOTD.logger().warn("Failed to reload MiniMOTD. Ensure there are no errors in your config files.", ex);
audience.sendMessage(Components.ofChildren(
audience.sendMessage(Component.textOfChildren(
Constants.COMMAND_PREFIX,
space(),
text("Failed to reload MiniMOTD. Ensure there are no errors in your config files. See console for more details.", RED)
@@ -85,7 +84,7 @@ public final class CommandHandler {
return;
}
audience.sendMessage(Components.ofChildren(
audience.sendMessage(Component.textOfChildren(
Constants.COMMAND_PREFIX,
space(),
text("Done reloading configuration.", GREEN)
@@ -35,7 +35,6 @@ import org.checkerframework.framework.qual.DefaultQualifier;
import org.slf4j.Logger;
import xyz.jpenilla.minimotd.common.config.ConfigManager;
import xyz.jpenilla.minimotd.common.config.MOTDConfig;
import xyz.jpenilla.minimotd.common.util.Components;
import static net.kyori.adventure.text.Component.newline;
@@ -91,7 +90,7 @@ public final class MiniMOTD<I> {
}
final int index = config.motds().size() == 1 ? 0 : ThreadLocalRandom.current().nextInt(config.motds().size());
final MOTDConfig.MOTD motdConfig = config.motds().get(index);
final Component motd = Components.ofChildren(
final Component motd = Component.textOfChildren(
parse(motdConfig.line1(), count),
newline(),
parse(motdConfig.line2(), count)
@@ -1,47 +0,0 @@
/*
* This file is part of MiniMOTD, licensed under the MIT License.
*
* Copyright (c) 2020-2024 Jason Penilla
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*/
package xyz.jpenilla.minimotd.common.util;
import net.kyori.adventure.text.ComponentLike;
import net.kyori.adventure.text.TextComponent;
import org.checkerframework.checker.nullness.qual.NonNull;
import org.checkerframework.framework.qual.DefaultQualifier;
import static net.kyori.adventure.text.Component.empty;
import static net.kyori.adventure.text.Component.text;
@DefaultQualifier(NonNull.class)
public final class Components {
private Components() {
throw new IllegalStateException();
}
public static TextComponent ofChildren(final ComponentLike... children) {
if (children.length == 0) {
return empty();
}
return text().append(children).build();
}
}
@@ -41,14 +41,14 @@ class ComponentColorDownsamplerTest {
@Test
void testColorDownsampling() {
final Component fullColor = Components.ofChildren(
final Component fullColor = Component.textOfChildren(
text("Green ", GREEN),
text("Orange Yellow ", ORANGE_YELLOW),
text("Pink ", PINK),
text("Blue ", BLUE),
text("Lime Green", LIME_GREEN)
);
final Component expectedDownsample = Components.ofChildren(
final Component expectedDownsample = Component.textOfChildren(
text("Green ", nearestTo(GREEN)),
text("Orange Yellow ", nearestTo(ORANGE_YELLOW)),
text("Pink ", nearestTo(PINK)),
+1 -1
View File
@@ -1,5 +1,5 @@
group=xyz.jpenilla
version=2.1.0
version=2.1.2-SNAPSHOT
description=Use MiniMessage text formatting in the server list MOTD.
org.gradle.caching=true
@@ -30,5 +30,6 @@ val bukkitVersions = listOf(
"1.17.1",
"1.18.2",
"1.19.4",
"1.20.4"
"1.20.6",
"1.21",
)
@@ -1,6 +1,6 @@
plugins {
id("minimotd.platform-conventions")
id("com.github.johnrengelman.shadow")
id("io.github.goooler.shadow")
}
tasks {
+16 -16
View File
@@ -6,28 +6,28 @@ run-velocity = { id = "xyz.jpenilla.run-velocity", version.ref = "run-task" }
run-waterfall = { id = "xyz.jpenilla.run-waterfall", version.ref = "run-task" }
[versions]
run-task = "2.2.2"
mod-publish-plugin = "0.4.5"
hangarPublishPlugin = "0.1.1"
run-task = "2.3.0"
mod-publish-plugin = "0.5.1"
hangarPublishPlugin = "0.1.2"
indra = "3.1.3"
shadow = "8.1.1"
adventure = "4.15.0"
adventurePlatform = "4.3.2"
adventurePlatformFabric = "5.11.0-SNAPSHOT"
shadow = "8.1.7"
adventure = "4.17.0"
adventurePlatform = "4.3.3"
adventurePlatformFabric = "5.14.0-SNAPSHOT"
configurate = "4.1.2"
checkerQual = "3.42.0"
checkerQual = "3.43.0"
slf4j = "1.7.32"
gson = "2.8.0"
bstats = "3.0.2"
paperApi = "1.16.5-R0.1-SNAPSHOT"
paperlib = "1.0.8"
waterfallApi = "1.16-R0.4-SNAPSHOT"
fabricApi = "0.93.1+1.20.4"
fabricLoader = "0.15.3"
minecraft = "1.20.4"
spongeApi7 = "7.2.0"
velocityApi = "3.2.0-SNAPSHOT"
jupiterEngine = "5.10.1"
waterfallApi = "1.16-R0.5-SNAPSHOT"
fabricApi = "0.100.3+1.21"
fabricLoader = "0.15.11"
minecraft = "1.21"
spongeApi7 = "7.4.0"
velocityApi = "3.3.0-SNAPSHOT"
jupiterEngine = "5.10.2"
[libraries]
adventureBom = { group = "net.kyori", name = "adventure-bom", version.ref = "adventure" }
@@ -72,7 +72,7 @@ jupiterEngine = { group = "org.junit.jupiter", name = "junit-jupiter-engine", ve
# build-logic
indraCommon = { group = "net.kyori", name = "indra-common", version.ref = "indra" }
indraLicenser = { group = "net.kyori", name = "indra-licenser-spotless", version.ref = "indra" }
shadow = { group = "com.github.johnrengelman", name = "shadow", version.ref = "shadow" }
shadow = { group = "io.github.goooler.shadow", name = "shadow-gradle-plugin", version.ref = "shadow" }
mod-publish-plugin = { module = "me.modmuss50:mod-publish-plugin", version.ref = "mod-publish-plugin" }
hangarPublishPlugin = { group = "io.papermc", name = "hangar-publish-plugin", version.ref = "hangarPublishPlugin" }
Binary file not shown.
+1 -1
View File
@@ -1,6 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.5-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.8-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
Vendored
+1 -1
View File
@@ -55,7 +55,7 @@
# Darwin, MinGW, and NonStop.
#
# (3) This script is generated from the Groovy template
# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
# https://github.com/gradle/gradle/blob/HEAD/platforms/jvm/plugins-application/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
# within the Gradle project.
#
# You can find Gradle at https://github.com/gradle/gradle/.
Vendored
+10 -10
View File
@@ -43,11 +43,11 @@ set JAVA_EXE=java.exe
%JAVA_EXE% -version >NUL 2>&1
if %ERRORLEVEL% equ 0 goto execute
echo.
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
echo. 1>&2
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 1>&2
echo. 1>&2
echo Please set the JAVA_HOME variable in your environment to match the 1>&2
echo location of your Java installation. 1>&2
goto fail
@@ -57,11 +57,11 @@ set JAVA_EXE=%JAVA_HOME%/bin/java.exe
if exist "%JAVA_EXE%" goto execute
echo.
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
echo. 1>&2
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 1>&2
echo. 1>&2
echo Please set the JAVA_HOME variable in your environment to match the 1>&2
echo location of your Java installation. 1>&2
goto fail
+3
View File
@@ -23,6 +23,9 @@ tasks {
commonRelocation("net.kyori")
commonRelocation("org.bstats")
commonRelocation("io.papermc.lib")
manifest {
attributes("paperweight-mappings-namespace" to "mojang")
}
}
processResources {
val props = mapOf(
+2 -2
View File
@@ -1,7 +1,7 @@
plugins {
id("quiet-fabric-loom")
id("minimotd.platform-conventions")
id("com.github.johnrengelman.shadow")
id("io.github.goooler.shadow")
}
val shade: Configuration by configurations.creating
@@ -26,7 +26,7 @@ miniMOTDPlatform {
indra {
javaVersions {
target(17)
target(21)
}
}
@@ -23,8 +23,8 @@
"minimotd-fabric.mixins.json"
],
"depends": {
"fabricloader": ">=0.15.3",
"fabricloader": ">=0.15.11",
"fabric": "*",
"minecraft": "~1.20.4"
"minecraft": "~1.21"
}
}
+2 -1
View File
@@ -53,6 +53,7 @@ publishMods.modrinth {
"1.17.1",
"1.18.2",
"1.19.4",
"1.20.4"
"1.20.6",
"1.21",
)
}
+7 -2
View File
@@ -2,7 +2,12 @@ enableFeaturePreview("TYPESAFE_PROJECT_ACCESSORS")
dependencyResolutionManagement {
repositories {
mavenCentral()
mavenCentral {
mavenContent { releasesOnly() }
}
maven("https://oss.sonatype.org/content/repositories/snapshots/") {
mavenContent { snapshotsOnly() }
}
maven("https://s01.oss.sonatype.org/content/repositories/snapshots/") {
mavenContent { snapshotsOnly() }
}
@@ -25,7 +30,7 @@ pluginManagement {
}
plugins {
id("quiet-fabric-loom") version "1.5-SNAPSHOT"
id("quiet-fabric-loom") version "1.6-SNAPSHOT"
id("org.gradle.toolchains.foojay-resolver-convention") version "0.8.0"
}