fix: make interactive var global
This commit is contained in:
parent
ac6be60d95
commit
625b5d0815
4
setup.sh
4
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"
|
||||
|
Loading…
Reference in New Issue
Block a user