Add internet connection check
This commit is contained in:
parent
791ce4da4e
commit
78672b0e31
|
@ -190,6 +190,7 @@ function installer_utils_check_dependencies() {
|
||||||
# Parameters: $1 - CLI Tools missing array (will be installed) $2 - substitutes array
|
# Parameters: $1 - CLI Tools missing array (will be installed) $2 - substitutes array
|
||||||
function installer_utils_run_dependencies() {
|
function installer_utils_run_dependencies() {
|
||||||
if [ ! "$1" ]; then return 1; fi
|
if [ ! "$1" ]; then return 1; fi
|
||||||
|
ping -q -w 1 -c 8.8.8.8 > /dev/null || echo -e "\n[!] No internet connection found"; exit 1
|
||||||
|
|
||||||
# The array below holds all the packages that will be installed.
|
# The array below holds all the packages that will be installed.
|
||||||
local __installer_utils_run_dependencies__dependenciesInfo=("${!1}")
|
local __installer_utils_run_dependencies__dependenciesInfo=("${!1}")
|
||||||
|
|
Loading…
Reference in New Issue