From 40effe1d232f88c046f29ba356a40c65d0e52973 Mon Sep 17 00:00:00 2001 From: Marco Nelissen Date: Sun, 27 Nov 2022 12:55:26 -0800 Subject: [PATCH] armbian-firstlogin: remove unnecessary check Commit c90986492252a85db3357362594e5c40b80fbf95 removed a prompt asking the user if they want to change display settings, but didn't remove the checks that later used the answer. Since it's been like this for 2 years now apparently without issue, remove the checks and the shellcheck workaround. --- packages/bsp/common/usr/lib/armbian/armbian-firstlogin | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/packages/bsp/common/usr/lib/armbian/armbian-firstlogin b/packages/bsp/common/usr/lib/armbian/armbian-firstlogin index 750afe40b0..be2a2bc0a3 100644 --- a/packages/bsp/common/usr/lib/armbian/armbian-firstlogin +++ b/packages/bsp/common/usr/lib/armbian/armbian-firstlogin @@ -411,7 +411,6 @@ if [[ -f /root/.not_logged_in_yet && -n $(tty) ]]; then printf "\nYou selected \e[0;91mZSH\x1B[0m as your default shell. If you want to use it right away, please logout and login! \n\n" fi - declare ConfigureDisplay # check whether desktop environment has to be considered if [ -n "$desktop_lightdm" ] && [ -n "$RealName" ] ; then @@ -454,7 +453,7 @@ if [[ -f /root/.not_logged_in_yet && -n $(tty) ]]; then # Let the user reboot now otherwise start desktop environment printf "\n\n\e[0;91mWarning: a reboot is needed to finish resizing the filesystem \x1B[0m \n" printf "\e[0;91mPlease reboot the system now \x1B[0m \n\n" - elif [ -z "$ConfigureDisplay" ] || [ "$ConfigureDisplay" = "n" ] || [ "$ConfigureDisplay" = "N" ]; then + else echo -e "\n\e[1m\e[39mNow starting desktop environment...\x1B[0m\n" sleep 1 service lightdm start 2>/dev/null @@ -486,7 +485,7 @@ if [[ -f /root/.not_logged_in_yet && -n $(tty) ]]; then printf "\n\n\e[0;91mWarning: a reboot is needed to finish resizing the filesystem \x1B[0m \n" printf "\e[0;91mPlease reboot the system now \x1B[0m \n\n" - elif [ -z "$ConfigureDisplay" ] || [ "$ConfigureDisplay" = "n" ] || [ "$ConfigureDisplay" = "N" ]; then + else echo -e "\n\e[1m\e[39mNow starting desktop environment...\x1B[0m\n" sleep 1