From 7a89eca36aceda4d998af6a990b91195283cb876 Mon Sep 17 00:00:00 2001 From: Kevin Veen-Birkenbach Date: Sun, 21 Aug 2022 09:45:26 +0200 Subject: [PATCH] Updated install procedures for manjaro --- scripts/base.sh | 2 +- scripts/image/setup.sh | 21 +++++++++++++++++---- 2 files changed, 18 insertions(+), 5 deletions(-) diff --git a/scripts/base.sh b/scripts/base.sh index eac1a79..d8450f8 100644 --- a/scripts/base.sh +++ b/scripts/base.sh @@ -108,7 +108,7 @@ get_packages(){ HEADER(){ echo echo "${COLOR_YELLOW}The" - base64 -d <<<"ICBfX19fXyAgICAgICAgICAgICAgICBfX19fXyAgICAgICAgICAgXyAgICAgICAgICAgICAgICAgCiAvIF9fX198ICAgICAgICAgICAgICAvIF9fX198ICAgICAgICAgfCB8ICAgICAgICAgICAgICAgIAp8IHwgICAgIF9fXyAgXyBfXyBfX198IChfX18gIF8gICBfIF9fX3wgfF8gX19fIF8gX18gX19fICAKfCB8ICAgIC8gXyBcfCAnX18vIF8gXFxfX18gXHwgfCB8IC8gX198IF9fLyBfIFwgJ18gYCBfIFwgCnwgfF9fX3wgKF8pIHwgfCB8ICBfXy9fX19fKSB8IHxffCBcX18gXCB8fCAgX18vIHwgfCB8IHwgfAogXF9fX19fXF9fXy98X3wgIFxfX198X19fX18vIFxfXywgfF9fXy9cX19cX19ffF98IHxffCB8X3wKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgX18vIHwgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfF9fXy8gICAgICAgICAgICAgICAgICAgICAgIAo=" + echo "LINUX IMAGE MANAGER" echo "is an administration tool designed from and for Kevin Veen-Birkenbach." echo echo "Licensed under GNU GENERAL PUBLIC LICENSE Version 3" diff --git a/scripts/image/setup.sh b/scripts/image/setup.sh index bf214cd..29458bd 100644 --- a/scripts/image/setup.sh +++ b/scripts/image/setup.sh @@ -36,7 +36,7 @@ getent passwd "$origin_username" > /dev/null 2 || error "User $origin_username d origin_user_home="/home/$origin_username/" info "Image routine starts..." -image_folder="$origin_user_home""Images/"; +image_folder="$origin_user_home""Software/Images/"; info "The images will be stored in \"$image_folder\"." if [ ! -d "$image_folder" ]; then info "Folder \"$image_folder\" doesn't exist. It will be created now." && @@ -86,9 +86,8 @@ case "$os" in imagename="manjaro-gnome-20.0-200426-linux56.iso" ;; "21") - image_checksum="3ee5c59d21b1d78ec7fc655acc8f05c47237c6c0" - base_download_url="https://download.manjaro.org/gnome/21.2rc1/" - imagename="manjaro-gnome-21.2rc1-211211-linux515.iso" + base_download_url="https://download.manjaro.org/gnome/21.3.7/" + imagename="manjaro-gnome-21.3.7-220816-linux515.iso" ;; esac ;; @@ -148,6 +147,20 @@ if [ -f "$image_path" ] wget "$download_url" -O "$image_path" || error "Download from \"$download_url\" failed." fi + +if [ -z "$image_checksum" ] + then + sha1_download_url="$download_url.sha1" + info "Image Chechsum is not defined. Try to download image signature from $sha1_download_url" + if wget -q --method=HEAD "$sha1_download_url"; + then + image_checksum="$(wget $sha1_download_url -q -O -)" + info "Defined image_checksum as $image_checksum" + else + warning "No checksum found under $sha1_download_url." + fi +fi + info "Verifying image..." if [[ -v image_checksum ]] then