From dd456d1055150b42e0afd6107c3311b2b6674ad8 Mon Sep 17 00:00:00 2001 From: pyr0ball Date: Fri, 26 Aug 2022 22:33:11 -0700 Subject: [PATCH] added dependency install function --- install.sh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/install.sh b/install.sh index 2c0bead..aa936db 100644 --- a/install.sh +++ b/install.sh @@ -79,6 +79,12 @@ remove(){ done } +install-deps(){ + if [[ $runuser == root ]] ; then + apt install -y $packages && success "Dependencies installed successfully!" || fail "Dependency install failed" + else + fail "Dependency install must be run as user 'root'" + fi } update(){ @@ -101,6 +107,8 @@ case $1 in remove ;; -d | --dependencies) + install-deps + ;; -u | --update) update #sleep $ratelimit