From ac34a63d9246b31e086932163dc652e7c90aa16f Mon Sep 17 00:00:00 2001 From: Ferks <69549678+Ferks-FK@users.noreply.github.com> Date: Tue, 15 Mar 2022 02:36:40 -0400 Subject: [PATCH] Add new verification function --- install.sh | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/install.sh b/install.sh index bcb077c..2881f79 100644 --- a/install.sh +++ b/install.sh @@ -3,7 +3,7 @@ set -e ######################################################## -# +# # Pterodactyl-AutoThemes Installation # # Created and maintained by Ferks-FK @@ -21,6 +21,7 @@ curl --silent \ sed -E 's/.*"([^"]+)".*/\1/' } +GITHUB_STATUS_URL="https://www.githubstatus.com" SCRIPT_VERSION="$(get_release)" # Visual Functions # @@ -35,6 +36,7 @@ hyperlink() { echo -e "\e]8;;${1}\a${1}\e]8;;\a" } +YELLOW="\033[1;33m" RESET="\e[0m" RED='\033[0;31m' @@ -50,6 +52,13 @@ if [[ $EUID -ne 0 ]]; then exit 1 fi +# Check Git # +if [ -z "$SCRIPT_VERSION" ]; then + error "Could not get the version of the script using GitHub." + echo "* Please check on the site below if the 'API Requests' are as normal status." + echo -e "${YELLOW}$(hyperlink "$GITHUB_STATUS_URL")${RESET}" +fi + # Check Curl # if ! [ -x "$(command -v curl)" ]; then echo "* curl is required in order for this script to work."