From caf1504efe30f2cad3f1687b5d65edc3cd728d31 Mon Sep 17 00:00:00 2001 From: PiJARR <60171758+pijarr@users.noreply.github.com> Date: Tue, 27 Jun 2023 14:24:24 +1000 Subject: [PATCH] Minor update setup.sh Ensure Jackett source is fetched. Previously only using curl it was missed. Added support for curl or wget. --- setup.sh | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/setup.sh b/setup.sh index 68a1f64..7f45af9 100644 --- a/setup.sh +++ b/setup.sh @@ -154,12 +154,18 @@ case "${systemInfo}" in echo "" exit 1 ;; esac - ### END CHECK SYSTEM REQUIREMENTS AND ARCHITECTURE ### # Fetch latest jackett release from https://github.com/Jackett/Jackett/releases -jackett_latest=$(curl -s https://github.com/Jackett/Jackett/releases | sed -n 's/.*href="\([^"]*\).*/\1/p' | grep Linux${JACKETT_ARCH}.tar.gz -A 0 | head -n 1) -jackett_src_url="https://github.com${jackett_latest}" +if command -v curl >/dev/null 2>&1; then + # Run the curl command + jackett_latest=$(curl -s https://github.com/Jackett/Jackett/releases | sed -n 's/.*href="\([^"]*\).*/\1/p' | grep Linux${JACKETT_ARCH}.tar.gz -A 0 | head -n 1) + jackett_src_url="https://github.com${jackett_latest}" +else command -v wget >/dev/null 2>&1; then + # Run the wget command + jackett_latest=$(wget -qO- https://github.com/Jackett/Jackett/releases | sed -n 's/.*href="\([^"]*\).*/\1/p' | grep Linux${JACKETT_ARCH}.tar.gz -A 0 | head -n 1) + jackett_src_url="https://github.com${jackett_latest}" +fi # Fetch latest radarr, lidarr and sonarr builds. Links below select latest release. radarr_src_url="https://radarr.servarr.com/v1/update/master/updatefile?os=linux&runtime=netcore&arch=${SERVARR_ARCH}"