fix: 修复插件自动更新时下载 URL 显示错误的问题
All checks were successful
Publish Project / build (push) Successful in 2m45s

This commit is contained in:
2025-07-30 20:41:56 +08:00
parent d16602a06d
commit 594bdf15b6
3 changed files with 7 additions and 7 deletions

View File

@@ -24,9 +24,9 @@ repositories {
dependencies { dependencies {
// 对于 Bukkit 插件 // 对于 Bukkit 插件
compileOnly("cn.hamster3.mc.plugin:core-bukkit:1.4.1") compileOnly("cn.hamster3.mc.plugin:core-bukkit:1.4.2")
// 对于 BungeeCord 插件 // 对于 BungeeCord 插件
compileOnly("cn.hamster3.mc.plugin:core-bungee:1.4.1") compileOnly("cn.hamster3.mc.plugin:core-bungee:1.4.2")
} }
``` ```
@@ -52,13 +52,13 @@ dependencies {
<dependency> <dependency>
<groupId>cn.hamster3.mc.plugin</groupId> <groupId>cn.hamster3.mc.plugin</groupId>
<artifactId>core-bukkit</artifactId> <artifactId>core-bukkit</artifactId>
<version>1.4.1</version> <version>1.4.2</version>
</dependency> </dependency>
<!--对于 BungeeCord 插件--> <!--对于 BungeeCord 插件-->
<dependency> <dependency>
<groupId>cn.hamster3.mc.plugin</groupId> <groupId>cn.hamster3.mc.plugin</groupId>
<artifactId>core-bungee</artifactId> <artifactId>core-bungee</artifactId>
<version>1.4.1</version> <version>1.4.2</version>
</dependency> </dependency>
</dependencies> </dependencies>
</project> </project>

View File

@@ -5,7 +5,7 @@ plugins {
} }
group = "cn.hamster3.mc.plugin" group = "cn.hamster3.mc.plugin"
version = "1.4.1" version = "1.4.2"
description = "叁只仓鼠的 Minecraft 插件开发通用工具包" description = "叁只仓鼠的 Minecraft 插件开发通用工具包"
subprojects { subprojects {

View File

@@ -47,7 +47,7 @@ public final class UpdateCheckUtils {
case "GITEA_RELEASES": { case "GITEA_RELEASES": {
lastRelease = getGiteaLastRelease(baseUrl, gitRepo, gitToken); lastRelease = getGiteaLastRelease(baseUrl, gitRepo, gitToken);
if (downloadUrl == null) { if (downloadUrl == null) {
downloadUrl = URI.create(baseUrl).resolve(gitRepo).toString(); downloadUrl = URI.create(baseUrl).resolve("/" + gitRepo).toString();
} }
break; break;
} }
@@ -58,7 +58,7 @@ public final class UpdateCheckUtils {
} }
lastRelease = getGitlabLastRelease(baseUrl, projectID, gitToken); lastRelease = getGitlabLastRelease(baseUrl, projectID, gitToken);
if (downloadUrl == null) { if (downloadUrl == null) {
downloadUrl = URI.create(baseUrl).resolve(gitRepo).toString(); downloadUrl = URI.create(baseUrl).resolve("/" + gitRepo).toString();
} }
break; break;
} }