diff --git a/start-setup.sh b/start-setup.sh new file mode 100755 index 0000000..e67ce4c --- /dev/null +++ b/start-setup.sh @@ -0,0 +1,46 @@ +#!/bin/bash + +if [[ $(whoami) == "root" ]]; then + echo "Do not run as root!" + exit 2 +fi + +echo "" +echo "===============" +echo " Intro " +echo "===============" +echo "" + +script_PATH=$(pwd) + +if [[ -d /etc/apt ]]; then + while true; do + read -p "Are you using a Debian? (y/n)" answer + if [[ "${answer,,}" == "y" ]]; then + echo "bash script_PATH/debiansetup.sh" + break + elif [[ "${answer,,}" == "n" ]]; then + echo "Use a compatible system (Debian/Arch)" + break + else + echo "Invalid input 'y/n'" + fi + done +elif [[ -d /etc/pacman ]]; then + while true; do + read -p "Are you using a Arch? (y/n)" answer + echo "${answer,,}" + if [[ "${answer,,}" == "y" ]]; then + echo "bash script_PATH/archsetup.sh" + break + elif [[ "${answer,,}" == "n" ]]; then + echo "Use a compatible system (Debian/Arch)" + break + else + echo "Invalid input 'y/n'" + fi + done +else + echo "Error: Could not identify system." + exit 2 +fi