Add a plugin not found handler

This commit is contained in:
Nick Chambers 2021-07-18 12:03:04 -05:00
parent ac81f2400f
commit 0300365d51
1 changed files with 3 additions and 0 deletions

3
rowbot
View File

@ -92,6 +92,7 @@ run_callbacks() {
shift
while IFS= read -r; do
log_info "running callback %s" "$REPLY"
"$REPLY" "$@"
(( status |= $? ))
done < <(compgen -A function "$filter")
@ -767,6 +768,8 @@ plugin_run() {
for plugin in "${plugins[@]}"; do
"$plugin" "$@"
done
else
run_callbacks plugin_not_found_
fi
}