From 68ebd08205b5fef663fbf33bd4d833a7eea93b6f Mon Sep 17 00:00:00 2001 From: GermanBread Date: Mon, 3 May 2021 22:04:05 +0200 Subject: [PATCH] Useful stuff --- LULI.sh | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) diff --git a/LULI.sh b/LULI.sh index 60c58a0..d705956 100644 --- a/LULI.sh +++ b/LULI.sh @@ -62,20 +62,34 @@ Error() { } if [ "$TERM" = dumb ]; then - exit + exit 0 fi if [ $(id -u) -eq 0 ]; then Error "Don't run this script as root" - exit + exit 0 fi # Check if unzip is installed -if [ ! -e /usr/bin/unzip ]; then - Warning "Unzip does not seem to be installed!\n\tThis script depends on this package.\n\tInstall unzip and restart this script.\n\tPress enter if you believe that this is a false-positive." +if [ ! -e /bin/unzip ]; then + Warning "Unzip does not seem to be installed!\n\tThis script depends on this package.\n\tInstall unzip and restart this script." + Info "Press enter if you believe that this is a false-positive." read -r REPLY fi +# Library checks (should prevent issues like https://github.com/Lightcord/Lightcord/issues/240) +if [ ! -e /lib/libnspr4.so ] || [ ! -e /lib/libnss3.so ]; then + Warning "Some required libraries seem to not be installed!\n\tMake sure that both 'libnspr4.so' and 'libnss3.so' are present in '/lib'" + Info "Press enter if you believe that this is a false-positive." + read -r REPLY +fi + +# Bedrock Linux warning +if [ -d /bedrock ]; then + Info "Detected Bedrock Linux." + SubInfo "This script is executed in the $(tput bold && brl which && tput sgr0 && tput setaf 8) stratum. Mention this when filing a bug report!" +fi + cat << "logo_end" _ _ _ _ _ | | (_)__ _| |_| |_ __ ___ _ _ __| |