TheRemote/RaspberryPiMinecraft

Automatic Update to the latest version?

capsload2 opened this issue · 5 comments

Hello,

it would be cool to have something like Update.sh that checks for new Versions.

If you run the Script with ./Update.sh -f it should automatically download and install/update to the latest available Version, without asking. Through that, we could have a fully automatic updater.

Would be nice!

For now, you have to run SetupMinecraft.sh and confirm everything

Or i dont know, maybe implement into start.sh ---> the newest version, fetching with:

https://papermc.io/api/v1/paper/latest

and then replace there:

wget --spider --quiet https://papermc.io/api/v1/paper/**1.16.3**/latest/download
if [ "$?" != 0 ]; then
echo "Unable to connect to update website (internet connection may be down). Skipping update ..."
else
wget -O paperclip.jar https://papermc.io/api/v1/paper/**1.16.3**/latest/download
fi

Hello capsload2

I think this is a great idea although I don't quite know how to fetch the latest version with zero user input.
Nevertheless, I created a update script in my recent Pull Request so maybe we will get something similar to what you would like to achieve ;-)

Best regards,
Simylein

https://papermc.io/api/v1/paper and https://papermc.io/api/v2/projects/paper return the available versions. Using API v1 you can determine the latest version. Using API v2 you can get the latest release for each version group.

See https://papermc.io/api/docs/swagger-ui/index.html?configUrl=/api/openapi/swagger-config#/projects-controller/project

Thanks!

Hello,

I have this in my Bedrock version of the script but I can definitely explain why it doesn't have it.

In the past Minecraft (Java) has always had problems with big version launches. The new versions are always extremely laggy and have tons of bugs. You also can't go back to the older version once you start using it so most people wait quite a while before upgrading.

Maybe this one is going to be smooth for 1.17 but so far Paper doesn't even have a server for that version yet so we don't know how stable it's going to be. Some of the previous releases have been unplayable for 6 months to a year until Paper could figure out how to patch out all the added junk slowing down the servers from the new features etc. To this day there are servers that still run 1.12/1.13 era servers for these reasons if they have a massive player base (otherwise it crashes and lags too badly).

Hopefully that helps, if we start getting version releases we can absolutely add this or it could pretty easily be added with the code that's been presented here (that's exactly how I would do it and do it with the Bedrock edition). The last few releases have been really really rough though!