Update quickget

This commit is contained in:
zenobit 2022-01-31 01:15:53 +01:00 committed by GitHub
parent 18f92bc785
commit 3d30f8b1d7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 24 additions and 6 deletions

View File

@ -893,16 +893,34 @@ function get_openbsd() {
}
function get_void() {
local FLAVOR=""
local HASH=""
local ISO=""
local URL=""
local arch="x86_64"
# TODO: only one hardcoded version of void added.. Add more and make it automatic
local HASH_URL=""
validate_release "releases_void"
URL="https://alpha.de.repo.voidlinux.org/live/current"
ISO="void-live-x86_64-20210930-xfce.iso"
#ISO="void-live-${ARCH}${LIBC}-${VERSION}-${FLAVOR}.iso"
DATE=$(wget -q -O- "https://mirror.fit.cvut.cz/voidlinux/live/current/sha256sum.txt" | awk 'NR == 1' |cut -d'.' -f1| cut -d'-' -f4)
URL="http://mirror.fit.cvut.cz/voidlinux/live/current"
case ${RELEASE} in
base)
ISO="void-live-x86_64-${DATE}.iso";;
musl)
ISO="void-live-x86_64-musl-${DATE}.iso";;
xfce)
ISO="void-live-x86_64-${DATE}-xfce.iso";;
xfce-musl)
ISO="void-live-x86_64-musl-${DATE}-xfce.iso";;
esac
case ${RELEASE} in
base)
HASH="$(wget -q -O- "https://mirror.fit.cvut.cz/voidlinux/live/current/sha256sum.txt" | grep "void-live-x86_64-${DATE}.iso" | cut -d' ' -f4)";;
musl)
HASH="$(wget -q -O- "https://mirror.fit.cvut.cz/voidlinux/live/current/sha256sum.txt" | grep "void-live-x86_64-musl-${DATE}.iso" | cut -d' ' -f4)";;
xfce)
HASH="$(wget -q -O- "https://mirror.fit.cvut.cz/voidlinux/live/current/sha256sum.txt" | grep "void-live-x86_64-${DATE}-xfce.iso" | cut -d' ' -f4)";;
xfce-musl)
HASH="$(wget -q -O- "https://mirror.fit.cvut.cz/voidlinux/live/current/sha256sum.txt" | grep "void-live-x86_64-musl-${DATE}.iso" | cut -d' ' -f4)";;
esac
web_get "${URL}/${ISO}" "${VM_PATH}"
check_hash "${ISO}" "${HASH}"
make_vm_config "${ISO}"