From 3ea6e8008310d5698217fbc446781712c0a63ff4 Mon Sep 17 00:00:00 2001 From: fscarmen <62703343+fscarmen@users.noreply.github.com> Date: Sun, 2 Oct 2022 18:35:48 +0800 Subject: [PATCH] Update warp-go.sh --- warp-go.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/warp-go.sh b/warp-go.sh index 589b14d..bb0a5bf 100644 --- a/warp-go.sh +++ b/warp-go.sh @@ -299,7 +299,7 @@ check_dependencies() { else DEPS_CHECK=("ping" "wget" "curl" "systemctl" "ip") DEPS_INSTALL=(" inetutils-ping" " wget" " curl" " systemctl" " iproute2") - for c in "${DEPS_CHECK[@]}"; do ! type -p $c >/dev/null 2>&1 && DEPS+=$c; done + for ((c=0;c<${#DEPS_CHECK[@]};c++)); do ! type -p ${DEPS_CHECK[c]} >/dev/null 2>&1 && DEPS+=${DEPS_INSTALL[c]}; done if [ -n "$DEPS" ]; then info "\n $(text 8) $DEPS \n" ${PACKAGE_UPDATE[int]}