DistroHopper/OS/blendos
zen0bit c087af2323 tmp
2024-04-10 21:20:44 +02:00

30 lines
1.4 KiB
Text

INFO="BlendOS|Arch||https://blendos.co/|A seamless blend of all Linux distributions. Allows you to have an immutable, atomic and declarative Arch Linux system, with application support from several Linux distributions & Android.";;
function releases_blendos() {
local RLIST=""
# Pull the rss feed
wget -q https://sourceforge.net/projects/blendos/rss?path=/ISOs/ -O- | grep -E -o 'https://.*blendOS\.iso.*</media:hash' >/tmp/blendos-isos.rss
RLIST=$(grep -E -o 'https://.*blendOS\.iso.*</media:hash' /tmp/blendos-isos.rss | cut -d/ -f 8-9 | sort -r -t/ --key=2 |grep -e '16878' -e '168[8-9]')
echo "${RLIST}"
}
function get_blendos() {
local HASH=""
local URL=""
# BlendOS has more editions and releases but there's a tracker indirect and other issues
# so easier to use the rss feed
#
# We have to provide edition/release as RELEASE or have a major refactor
# But this works for now ... or does it ....
URL=$(grep ${RELEASE} /tmp/blendos-isos.rss | grep -E -o 'https://.*blendOS\.iso')
HASH=$(grep ${RELEASE} /tmp/blendos-isos.rss | grep -E -o '[[:alnum:]]{32}')
# ## fix up variables for path naming
EDITION=${RELEASE%%/*}
RELEASE=${RELEASE##*/}
# For UX maybe show the date of the release
#echo ${RELEASE##*/} "(" $(date -d @${RELEASE##*/}) ")"
# maybe $(date -d @${RELEASE##*/} '+%Y%m%d')
echo "${URL} ${HASH}"
}