From ee34c250dd5b017d2909b94995d0a412c85966b6 Mon Sep 17 00:00:00 2001
From: G2-Games <72430668+G2-Games@users.noreply.github.com>
Date: Tue, 20 Sep 2022 13:15:13 -0500
Subject: [PATCH] Finalized config version checker

---
 install.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/install.sh b/install.sh
index f2bda2a..a444c96 100755
--- a/install.sh
+++ b/install.sh
@@ -1,6 +1,5 @@
 version="${1:-1.0.2}"
 vernum=$(echo $version | sed 's/[.][.]*//g' )
-cfgver=2
 bashrc=~/.bashrc
 zshrc=~/.zshrc
 originaldir=$PWD
@@ -46,6 +45,7 @@ then
         tput sc
         echo -e "\e[35mwelcome.sh\e[0m already installed!"
         if [[ $vernum -gt $(grep version ~/.welcome/welcome.sh | sed 's/.*=//' | sed 's/[.][.]*//g') ]]; then
+            cfgver=$(echo $(curl -Ls https://github.com/G2-Games/welcome.sh/releases/download/v$version/config.cfg) | grep version | sed 's/.*=//' | sed 's/[.][.]*//g')
             echo -en "Do you want to \e[36mupdate \e[35mwelcome.sh\e[0m? (v$(grep version ~/.welcome/welcome.sh | sed 's/.*=//') => v$version) \n\e[36mY/n\e[0m"
             if [[ "$environment" = "bash" ]]; then read -p " " -n 1 -r;
             elif [[ "$environment" = "zsh" ]]; then read -q "REPLY? " -n 1 -r; fi