From 3ced16335cde5998f3b660dc4eef8b5582c12ea7 Mon Sep 17 00:00:00 2001 From: mfgbhatti Date: Mon, 24 Jan 2022 20:16:38 +0000 Subject: [PATCH] global function update --- startup.sh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/startup.sh b/startup.sh index fecff70..81e0258 100644 --- a/startup.sh +++ b/startup.sh @@ -32,6 +32,11 @@ check_root() { fi } +elements_present() { + # check if an element exists + for e in "${@:2}"; do [[ "$e" == "$1" ]] && break; done +} + invalid_option() { # invalid option message echo -ne "Please select a valid option: \n"