line 5: LATEST_VERSION=$(curl -s https://api.papermc.io/v2/projects/paper | \ the url is hardcoded to the paper project
line 12: JAR_NAME=paper-${LATEST_VERSION}-${LATEST_BUILD}.jar the filename is hardcoded to the paper project
line 14: PAPERMC_URL="https://api.papermc.io/v2/projects/paper/versions/${LATEST_VERSION}/builds/${LATEST_BUILD}/downloads/${JAR_NAME}" the url is hardcoded to the paper project.
This is a slightly modified version of the script that does support all projects and does not hard code any projects into the script
Hi there, thanks for pointing this out! This is the wrong repository though - would you mind closing this and reopening it on our PaperMC/docs repo. Thanks ☺️
in the script showed here it asks for a
project
entry but uses it only once and does not implement it in the way that it could support all projects.this is the script listed on the docs:
Let me list the flaws
LATEST_VERSION=$(curl -s https://api.papermc.io/v2/projects/paper | \
the url is hardcoded to the paper projectJAR_NAME=paper-${LATEST_VERSION}-${LATEST_BUILD}.jar
the filename is hardcoded to the paper projectPAPERMC_URL="https://api.papermc.io/v2/projects/paper/versions/${LATEST_VERSION}/builds/${LATEST_BUILD}/downloads/${JAR_NAME}"
the url is hardcoded to the paper project.This is a slightly modified version of the script that does support all projects and does not hard code any projects into the script