From de798af9b091720c8c8baa398ce6b91e91c744eb Mon Sep 17 00:00:00 2001 From: Martin Wimpress Date: Sat, 20 Apr 2024 10:53:52 +0100 Subject: [PATCH] refactor: simplify get_gentoo() --- quickget | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/quickget b/quickget index d2f76df..4e5668f 100755 --- a/quickget +++ b/quickget @@ -2182,13 +2182,10 @@ function get_gentoo() { local ISO="" local URL="https://mirror.bytemark.co.uk/gentoo/releases/amd64/autobuilds/" case ${EDITION} in - minimal) - ISO=$(web_pipe "${URL}/${RELEASE}-iso.txt" | grep install | cut_1) - HASH=$(web_pipe "${URL}/${ISO}.DIGESTS" | grep -A 1 SHA512 | grep iso | grep -v CONTENTS | cut_1);; - livegui) - ISO=$(web_pipe "${URL}/${RELEASE}-iso.txt" | grep livegui | cut -d' ' -f1) - HASH=$(web_pipe "${URL}/${ISO}.DIGESTS" | grep -A 1 SHA512 | grep iso | grep -v CONTENTS | cut_1);; + minimal) ISO=$(web_pipe "${URL}/${RELEASE}-iso.txt" | grep install | cut_1);; + livegui) ISO=$(web_pipe "${URL}/${RELEASE}-iso.txt" | grep livegui | cut_1);; esac + HASH=$(web_pipe "${URL}/${ISO}.DIGESTS" | grep -A 1 SHA512 | grep iso | grep -v CONTENTS | cut_1) echo "${URL}/${ISO} ${HASH}" }