From 0db22c38be7b026f7fea0316b25a5fd2a25ecd8a Mon Sep 17 00:00:00 2001 From: alarig Date: Sun, 6 May 2018 11:50:53 +0200 Subject: [PATCH] Add a script to check dependancies --- check_deps.sh | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 check_deps.sh diff --git a/check_deps.sh b/check_deps.sh new file mode 100644 index 0000000..9051415 --- /dev/null +++ b/check_deps.sh @@ -0,0 +1,16 @@ +#/bin/sh + +check_bin_in_path() { + if [ -z $(which $1 2>/dev/null) ]; then + MISSING="${MISSING} $1" + fi +} + +check_bin_in_path eix-sync +check_bin_in_path emerge +check_bin_in_path grep +check_bin_in_path cat +check_bin_in_path restart-services +check_bin_in_path sendmail + +printf "You’r missing this:${MISSING}\n"