Signed-off-by: fbt <fbt@fleshless.org>
This commit is contained in:
Jack L. Frost 2018-03-06 19:47:42 +03:00
parent dfd942ca49
commit 94bb395417

4
ssm
View File

@ -2,7 +2,7 @@
shopt -s nullglob shopt -s nullglob
# Utility functions # Utility functions
is_function() [[ $(type -t $1 2>/dev/null) == 'function' ]] is_function() [[ "$(type -t "$1" 2>/dev/null)" == 'function' ]]
readonly -f is_function readonly -f is_function
usage() { usage() {
@ -128,7 +128,7 @@ if_service_action() {
is_function "$f" && return 0 is_function "$f" && return 0
done done
return 0 return 1
}; readonly -f if_service_action }; readonly -f if_service_action
run_service_action() { run_service_action() {