From 01fbc2bbef689c31f004316acf0b5eef5213c209 Mon Sep 17 00:00:00 2001 From: Martin Wimpress Date: Sat, 21 Mar 2020 11:39:31 +0000 Subject: [PATCH] Vars refactor: Simplify initialisation of guest_os --- quickemu | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/quickemu b/quickemu index 1d7de79..b788769 100755 --- a/quickemu +++ b/quickemu @@ -113,14 +113,8 @@ function vm_boot() { echo " - BIOS: Legacy" fi - # If guest_os is unset, default to "linux" - if [ -z "${guest_os}" ]; then - guest_os="linux" - else - # Force to lowercase. - guest_os=$(echo ${guest_os,,}) - fi - + # Force to lowercase. + guest_os=$(echo ${guest_os,,}) # Make any OS specific adjustments case ${guest_os} in linux) @@ -312,7 +306,7 @@ function usage() { } # Lowercase variables are used in the VM config file only -guest_os="" +guest_os="linux" iso="" driver_iso="" disk_img=""