mirror of
https://github.com/LeavesMC/Leaves.git
synced 2025-12-19 14:59:32 +00:00
init
This commit is contained in:
25
scripts/paperclip.sh
Normal file
25
scripts/paperclip.sh
Normal file
@@ -0,0 +1,25 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Copied from https://github.com/PaperMC/Paper/blob/d54ce6c17fb7a35238d6b9f734d30a4289886773/scripts/paperclip.sh
|
||||
# License from Paper applies to this file
|
||||
|
||||
(
|
||||
set -e
|
||||
basedir="$(cd "$1" && pwd -P)"
|
||||
workdir="$basedir/Paper/work"
|
||||
mcver=$(cat "$workdir/BuildData/info.json" | grep minecraftVersion | cut -d '"' -f 4)
|
||||
paperjar="$basedir/Leaves-Server/target/leaves-$mcver.jar"
|
||||
vanillajar="$workdir/Minecraft/$mcver/$mcver.jar"
|
||||
|
||||
(
|
||||
cd "$workdir/Paperclip"
|
||||
mvn clean package "-Dmcver=$mcver" "-Dpaperjar=$paperjar" "-Dvanillajar=$vanillajar"
|
||||
)
|
||||
cp "$workdir/Paperclip/assembly/target/paperclip-${mcver}.jar" "$basedir/leaves-paperclip.jar"
|
||||
|
||||
echo ""
|
||||
echo ""
|
||||
echo ""
|
||||
echo "Build success!"
|
||||
echo "Copied final jar to $(cd "$basedir" && pwd -P)/leaves-paperclip.jar"
|
||||
) || exit 1
|
||||
Reference in New Issue
Block a user