From 14ce48b0362d6eaaee5c6e3a9430f7eb45eb1156 Mon Sep 17 00:00:00 2001 From: kaboom <58372747+kaboombot@users.noreply.github.com> Date: Sat, 23 Oct 2021 01:14:20 +0300 Subject: [PATCH] Add scripts for fetching latest versions of plugins --- .gitignore | 1 + scripts/fetch_external_plugins.sh | 29 +++++++++++++++++++++++++++++ scripts/fetch_internal_plugins.sh | 15 +++++++++++++++ 3 files changed, 45 insertions(+) create mode 100644 .gitignore create mode 100755 scripts/fetch_external_plugins.sh create mode 100755 scripts/fetch_internal_plugins.sh diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..42d1dc5 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +scripts/fetched_plugins/ diff --git a/scripts/fetch_external_plugins.sh b/scripts/fetch_external_plugins.sh new file mode 100755 index 0000000..669be34 --- /dev/null +++ b/scripts/fetch_external_plugins.sh @@ -0,0 +1,29 @@ +#!/bin/sh +# Script used to fetch latest versions of external plugins +# Plugins: EssentialsX, FastAsyncWorldEdit, GeyserMC, ViaVersion, ViaBackwards, ViaRewind + +mkdir -p fetched_plugins + +# Fetch plugins +for download_url in https://ci.ender.zone/job/EssentialsX/lastSuccessfulBuild/artifact/*zip*/archive.zip \ + https://ci.athion.net/job/FastAsyncWorldEdit-1.17/lastSuccessfulBuild/artifact/*zip*/archive.zip \ + https://ci.opencollab.dev/job/GeyserMC/job/Geyser/job/master/lastSuccessfulBuild/artifact/*zip*/archive.zip \ + https://ci.viaversion.com/job/ViaVersion/lastSuccessfulBuild/artifact/*zip*/archive.zip \ + https://ci.viaversion.com/job/ViaBackwards/lastSuccessfulBuild/artifact/*zip*/archive.zip \ + https://ci.viaversion.com/job/ViaRewind/lastSuccessfulBuild/artifact/*zip*/archive.zip +do + curl -L $download_url > archive.zip + unzip -o archive.zip + rm archive.zip +done + +# Move plugins +mv archive/jars/EssentialsX-*.jar fetched_plugins/Essentials.jar +mv archive/artifacts/FastAsyncWorldEdit-Bukkit-*.jar fetched_plugins/FastAsyncWorldEdit.jar +mv archive/bootstrap/spigot/target/Geyser-Spigot.jar fetched_plugins/Geyser.jar +mv archive/build/libs/ViaVersion-*.jar fetched_plugins/ViaVersion.jar +mv archive/build/libs/ViaBackwards-*.jar fetched_plugins/ViaBackwards.jar +mv archive/all/target/ViaRewind-*.jar fetched_plugins/ViaRewind.jar + +# Clean up +rm -rf archive/ diff --git a/scripts/fetch_internal_plugins.sh b/scripts/fetch_internal_plugins.sh new file mode 100755 index 0000000..28f858a --- /dev/null +++ b/scripts/fetch_internal_plugins.sh @@ -0,0 +1,15 @@ +#!/bin/sh +# Script used to fetch latest versions of internal plugins +# Plugins: CommandSpy, Extras, iControlU, Weapons + +mkdir -p fetched_plugins + +for download_url in https://nightly.link/kaboomserver/commandspy/workflows/main/master/CommandSpy.zip \ + https://nightly.link/kaboomserver/extras/workflows/main/master/Extras.zip \ + https://nightly.link/kaboomserver/icontrolu/workflows/main/master/iControlU.zip \ + https://nightly.link/kaboomserver/weapons/workflows/main/master/Weapons.zip +do + curl -L $download_url > archive.zip + unzip -o archive.zip -d fetched_plugins + rm archive.zip +done