mirror of
https://github.com/oSoWoSo/DistroHopper.git
synced 2026-12-06 04:43:46 +00:00
70 lines
1.8 KiB
Text
70 lines
1.8 KiB
Text
# Template file for 'zimaos'
|
|
OSNAME="zimaos"
|
|
PRETTY="ZimaOS"
|
|
LOGO=""
|
|
ICON="zimaos.svg"
|
|
ICON_ONLINE=""
|
|
CATEGORY="Server, NAS"
|
|
BASEDOF="Independent"
|
|
DESCRIPTION="A lightweight Linux-based operating system for personal servers and NAS devices, with remote access, RAID management, OTA updates, and a browser-based interface."
|
|
HOMEPAGE="https://github.com/IceWhaleTech/ZimaOS"
|
|
CREDENTIALS="-"
|
|
GPG=""
|
|
RSS=""
|
|
DW=""
|
|
MAGNET=""
|
|
MAGNET_PREFERRED=""
|
|
TORRENT=""
|
|
CHAT=""
|
|
|
|
RELEASES="1.8.1-beta1"
|
|
EDITIONS="installer"
|
|
EDITIONS_LIST="installer"
|
|
QEMU_ARCH="amd64"
|
|
|
|
releases_() {
|
|
web_pipe "https://api.github.com/repos/IceWhaleTech/ZimaOS/releases/latest" \
|
|
| jq -r '.tag_name // empty'
|
|
}
|
|
|
|
editions_() {
|
|
echo installer
|
|
}
|
|
|
|
arch_() {
|
|
echo amd64
|
|
}
|
|
|
|
get_() {
|
|
local RELEASE_JSON URL HASH
|
|
RELEASE_JSON=$(web_pipe "https://api.github.com/repos/IceWhaleTech/ZimaOS/releases/tags/${RELEASE}")
|
|
URL=$(jq -r --arg asset "zimaos-x86_64-${RELEASE}_installer.iso" \
|
|
'.assets[] | select(.name == $asset) | .browser_download_url' <<<"${RELEASE_JSON}")
|
|
HASH=$(jq -r --arg asset "zimaos-x86_64-${RELEASE}_installer.iso" \
|
|
'.assets[] | select(.name == $asset) | (.digest // "") | sub("^sha256:"; "")' \
|
|
<<<"${RELEASE_JSON}")
|
|
[ -n "${URL}" ] || return 1
|
|
echo "${URL} ${HASH}"
|
|
}
|
|
|
|
releases_() {
|
|
# Releases parsed at generation time — no network access needed.
|
|
echo "${RELEASES}"
|
|
}
|
|
editions_() {
|
|
# Editions parsed at generation time — no network access needed.
|
|
local _scoped=""
|
|
if [ -n "${RELEASE:-}" ] && declare -F _release_editions_ >/dev/null; then
|
|
_scoped=$(_release_editions_ "${ARCH:-}|${RELEASE}")
|
|
fi
|
|
if [ -n "${_scoped}" ]; then
|
|
echo "${_scoped}"
|
|
return 0
|
|
fi
|
|
local _per_arch="EDITIONS_${ARCH:-}"
|
|
if [ -n "${!_per_arch:-}" ]; then
|
|
echo "${!_per_arch}"
|
|
return 0
|
|
fi
|
|
echo "${EDITIONS:-}"
|
|
}
|