perf(quickget): call web_pipe once then use read builtin to split words

This commit is contained in:
MightyCoderX 2026-06-22 17:00:13 +02:00
parent 0f5f9a885b
commit 87db04b571
1 changed files with 4 additions and 2 deletions

View File

@ -2228,8 +2228,10 @@ function get_kdeneon() {
local HASH=""
local ISO=""
local URL="https://files.kde.org/neon/images/${EDITION}/${RELEASE}/current"
ISO=$(web_pipe "${URL}/neon-${RELEASE}-${EDITION}-current.sha256sum" | cut -d' ' -f3-)
HASH=$(web_pipe "${URL}/neon-${RELEASE}-${EDITION}-current.sha256sum" | cut -d' ' -f1)
local CHKSUM_FILE_CONTENT=$(web_pipe "${URL}/neon-${RELEASE}-${EDITION}-current.sha256sum")
IFS=' ' read -r HASH ISO <<< "$CHKSUM_FILE_CONTENT"
echo "${URL}/${ISO} ${HASH}"
}