From 787f4c2d02c1de984f3fc0a1e29586e067848501 Mon Sep 17 00:00:00 2001 From: eichehome Date: Tue, 12 Sep 2023 21:51:29 +0200 Subject: [PATCH] =?UTF-8?q?Anfang=20der=20Ausgabe=20des=20Auswahlmen=C3=BC?= =?UTF-8?q?s=20implementiert.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- script.uefi | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/script.uefi b/script.uefi index a46da69..38a052d 100755 --- a/script.uefi +++ b/script.uefi @@ -1,4 +1,4 @@ -#!/bin/bash -x +#!/bin/bash ### Konstanten ### declare -A GUIDS="" @@ -135,7 +135,7 @@ find_uuid_for_partition () { if [[ "$(existing_partitions "${DEVICE}" "${TYPE}")" == "yes" ]] then uuid=$(lsblk -lo PARTTYPE,PARTUUID "${DEVICE}" | grep "${GUIDS[${TYPE}]}" | awk '{ print $2 }') - echo "uuid: ${uuid}" + echo "${uuid}" else echo "null" fi @@ -183,8 +183,13 @@ format () { if [[ ${ask_overwrite} == [Nn] ]] then #die 10 "Noch nicht implementiert" - temp=$(partitions_analyse "${DEVICE}") - echo "${temp}" + ANALYSE_RESULT=$(partitions_analyse "${DEVICE}") + if [[ "${ANALYSE_RESULT}" =~ "null"+ ]] + then + echo "if" + else + echo "else" + fi #EXISTING_ESP=$(existing_partitions "${DEVICE}" "ESP") #if [[ "${EXISTING_ESP}" == "no" ]] #then