From 44170207ac37896e1990c87649f33b559482ae57 Mon Sep 17 00:00:00 2001 From: Dan Schaper Date: Sat, 8 Oct 2016 12:17:04 -0700 Subject: [PATCH] Add `main` function and fire script from `main` call. Prevents script from running before it is entirely downloaded. --- automated install/basic-install.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/automated install/basic-install.sh b/automated install/basic-install.sh index 4dab9355..85e93d00 100755 --- a/automated install/basic-install.sh +++ b/automated install/basic-install.sh @@ -903,7 +903,7 @@ updateDialogs(){ } -######## SCRIPT ############ +main() { if [[ -f ${setupVars} ]];then . ${setupVars} @@ -979,3 +979,6 @@ fi echo ":::" echo "::: The install log is located at: /etc/pihole/install.log" echo "::: View the web interface at http://pi.hole/admin or http://${IPv4addr%/*}/admin" +} + +main "$@" \ No newline at end of file