aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorkaotisk <kaotisk@arching-kaos.org>2024-07-05 01:01:38 +0300
committerkaotisk <kaotisk@arching-kaos.org>2024-07-05 01:01:38 +0300
commitea2aca3ad219fd838575c7ca1763ccc0123b653a (patch)
tree3fa8205242ceb65c2887f4fbdee15ea8a6d21821
parent681358adcfc8d1471ca53c3af246bf80a885ef98 (diff)
downloadarching-kaos-tools-ea2aca3ad219fd838575c7ca1763ccc0123b653a.tar.gz
arching-kaos-tools-ea2aca3ad219fd838575c7ca1763ccc0123b653a.tar.bz2
arching-kaos-tools-ea2aca3ad219fd838575c7ca1763ccc0123b653a.zip
duh: check before running whatever, provide nice message
-rwxr-xr-xbin/ak5
1 files changed, 5 insertions, 0 deletions
diff --git a/bin/ak b/bin/ak
index 7ca3f3c..edf439d 100755
--- a/bin/ak
+++ b/bin/ak
@@ -69,6 +69,11 @@ case "$1" in
exit 1
fi
subargs="$*"
+ if [ ! -f $subcmd/main.sh ]
+ then
+ _ak_log_error "No $(basename $subcmd) module"
+ exit 1
+ fi
$subcmd/main.sh $subargs
_ak_exit_program $? "$subcmd module finished";
;;