From 215294866cf14e70a77d2a5f16beaee514367ffa Mon Sep 17 00:00:00 2001 From: Sekwah Date: Tue, 10 Dec 2024 04:32:41 +0000 Subject: [PATCH] chore: add old changelog --- CHANGELOG.md | 4 ++-- discord.gradle | 11 ++++++++--- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0813ac92..f0f55165 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,11 +4,11 @@ **This is not the re-code, I released some breaking config changes for servers that used to rely on the automatic proxy detection.** -#### 💥 Breaking Change +### 💥 Breaking Change - fix!: disable proxy detection to avoid vulnerabilities (see full commit for more info) [#436](https://github.com/sekwah41/Advanced-Portals/pull/436) ([@sekwah41](https://github.com/sekwah41)) - fix: stop portal packets still being forwarded to the client [#436](https://github.com/sekwah41/Advanced-Portals/pull/436) ([@sekwah41](https://github.com/sekwah41)) -#### Authors: 1 +### Authors: 1 - Sekwah ([@sekwah41](https://github.com/sekwah41)) \ No newline at end of file diff --git a/discord.gradle b/discord.gradle index 6e7e6168..09b06d12 100644 --- a/discord.gradle +++ b/discord.gradle @@ -36,16 +36,21 @@ task discordupload { } else { def maxLength = 2000 - def content = "New release build\n" + + def content = "# New release build\n" + "${getReleaseChangelog()}\n" if (content.length() > maxLength) { - def afterMessage = "[See more on GitHub]" - content = "${content.take(maxLength - afterMessage.length() - 1)}\n" + + def afterMessage = "[See more on GitHub](https://github.com/sekwah41/Advanced-Portals/releases)" + + def truncatedContent = content.take(maxLength - afterMessage.length() - 1) + def lastFullLine = truncatedContent.lastIndexOf("\n") + content = "${truncatedContent.take(lastFullLine)}\n" + "${afterMessage}" } + content = content.replaceAll(/(http[s]?:\/\/[^\s)]+)/, '<$1>') + builder.addTextBody("content", content, ContentType.create("text/plain", "UTF-8")) }