From 625b5d081564109501745c38081c48aa544723de Mon Sep 17 00:00:00 2001 From: Jim Richter Date: Thu, 19 Aug 2021 16:10:28 +0200 Subject: [PATCH] fix: make interactive var global --- setup.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/setup.sh b/setup.sh index f211765..3efb559 100755 --- a/setup.sh +++ b/setup.sh @@ -1,6 +1,8 @@ #!/bin/bash cd "$(dirname "$0")" +INTERACTIVE=$(tty -s && echo "true" || echo "false") + #Loading all the helper scripts . ./helpers/installer.sh --source-only . ./helpers/prompt.sh --source-only @@ -14,8 +16,6 @@ if [ "$(which git)" = "" ] && ["$(which curl)" = ""]; then echo "-- installing prerequesits (git, curl) --" - INTERACTIVE=$(tty -s && echo "true" || echo "false") - if [ $INTERACTIVE = "true" ]; then if [ "$(prompt " - do you want to continue")" != "yes" ]; then echo " alllrighty then, byyye"