fail if check doesnt exist

Signed-off-by: Thomas Sjögren <konstruktoid@users.noreply.github.com>
This commit is contained in:
Thomas Sjögren 2018-01-18 11:29:02 +01:00
parent 83ed8122ef
commit 57365ba1e4

View file

@ -112,7 +112,12 @@ main () {
if [ -z "$check" ]; then
cis
else
if command -v "$check" 2>/dev/null 1>&2; then
"$check"
else
echo "Check \"$check\" doesn't seem to exist."
exit 1
fi
fi
printf "\n"