mirror of
https://github.com/oSoWoSo/DistroHopper.git
synced 2024-08-14 22:46:53 +00:00
Updated manjaro fetching as migrated to new system (#742)
* Updated manjaro fetching - Added sway release - Added choice to download minimal or full edition * Future proofing manjaro sway fetching * Forgot this kde -> plasma * Fix a typo * Update quickget
This commit is contained in:
parent
af051339ba
commit
392e74c16b
1 changed files with 33 additions and 7 deletions
40
quickget
40
quickget
|
@ -472,6 +472,10 @@ function editions_mxlinux(){
|
|||
echo Xfce KDE Fluxbox
|
||||
}
|
||||
|
||||
function editions_manjaro(){
|
||||
echo full minimal
|
||||
}
|
||||
|
||||
function releases_macos() {
|
||||
echo high-sierra mojave catalina big-sur monterey ventura
|
||||
}
|
||||
|
@ -479,11 +483,12 @@ function releases_macos() {
|
|||
function releases_manjaro() {
|
||||
echo xfce \
|
||||
gnome \
|
||||
kde \
|
||||
plasma \
|
||||
budgie \
|
||||
cinnamon \
|
||||
i3 \
|
||||
mate
|
||||
mate \
|
||||
sway
|
||||
}
|
||||
|
||||
function releases_netboot() {
|
||||
|
@ -1487,18 +1492,30 @@ function get_mageia() {
|
|||
}
|
||||
|
||||
function get_manjaro() {
|
||||
local EDITION="${1:-}"
|
||||
local HASH=""
|
||||
local ISO=""
|
||||
local MANIFESTURL=""
|
||||
local MANIFEST=""
|
||||
local URL=""
|
||||
local TYPE=""
|
||||
|
||||
case ${RELEASE} in
|
||||
gnome|kde|xfce) MANIFESTURL="https://gitlab.manjaro.org/webpage/manjaro-homepage/-/raw/master/site/content/downloads/official/${RELEASE}.md";;
|
||||
budgie|cinnamon|deepin|i3|mate) MANIFESTURL="https://gitlab.manjaro.org/webpage/manjaro-homepage/-/raw/master/site/content/downloads/community/${RELEASE}.md";;
|
||||
sway) MANIFEST="$( wget -qO- https://mirror.manjaro-sway.download/manjaro-sway/release.json )";;
|
||||
gnome|xfce|plasma) TYPE="official";;
|
||||
*) TYPE="community";;
|
||||
esac
|
||||
|
||||
URL="$(wget -qO- "${MANIFESTURL}" | grep "Download_x64 =" | cut -d'"' -f2)"
|
||||
HASH=$(wget -qO- "${MANIFESTURL}" | grep "Download_x64_Checksum =" | cut -d'"' -f2)
|
||||
[[ ${RELEASE} != "sway" ]] && MANIFEST="$(wget -qO- https://gitlab.manjaro.org/web/iso-info/-/raw/master/file-info.json)"
|
||||
|
||||
[[ ${EDITION} == "minimal" && ${TYPE} != "sway" ]] && EDITION=".minimal" || EDITION=""
|
||||
|
||||
if [[ ${RELEASE} != "sway" ]]; then
|
||||
URL="$(echo ${MANIFEST} | jq -r .${TYPE}.${RELEASE}${EDITION}.image)"
|
||||
else
|
||||
URL=$(echo ${MANIFEST} | jq -r '.[] | select(.name|test("^manjaro-sway-.*[.]iso$")) | select(.name|contains("unstable")|not) | .url')
|
||||
fi
|
||||
|
||||
HASH=$(wget -qO- "${URL}.sha512" | cut -d' ' -f1)
|
||||
echo "${URL} ${HASH}"
|
||||
}
|
||||
|
||||
|
@ -2289,6 +2306,15 @@ if [ -n "${2}" ]; then
|
|||
fi
|
||||
fi
|
||||
|
||||
# Handle missing Mangaro Sway minimal
|
||||
if [[ $OS == manjaro ]] ; then
|
||||
if [[ ${RELEASE} == "sway" && ${EDITION} == "minimal" ]] ; then
|
||||
echo "ERROR! Unsupported combination"
|
||||
echo " Manjaro Sway does not have a minimal edition"
|
||||
exit 1;
|
||||
fi
|
||||
fi
|
||||
|
||||
|
||||
VM_PATH="${OS}-${RELEASE}-${EDITION}"
|
||||
validate_release "releases_${OS}"
|
||||
|
|
Loading…
Reference in a new issue