From 761ae2bdd5a5742d218bed5f60d1d394ccf8a36d Mon Sep 17 00:00:00 2001 From: Martin Wimpress Date: Sun, 28 Apr 2024 02:47:23 +0100 Subject: [PATCH] refactor: make alpine dynamic and check for releases --- quickget | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/quickget b/quickget index 6b32fe6..8e12017 100755 --- a/quickget +++ b/quickget @@ -601,7 +601,13 @@ function editions_alma() { } function releases_alpine() { - echo latest 3.19 3.18 3.17 3.16 3.15 3.14 3.13 3.12 + local REL="" + local RELS=$(web_pipe "https://dl-cdn.alpinelinux.org/alpine/" | grep '"v' | cut -d'"' -f2 | tr -d / | sort -Vr | head -n 10) + for REL in ${RELS}; do + if web_check "https://dl-cdn.alpinelinux.org/alpine/${REL}/releases/x86_64/"; then + echo -n "${REL} " + fi + done } function releases_android() {