diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-06 01:48:40 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-06 01:48:40 +0000 |
commit | 73e1fa4347d6c81c6e64054957ab436fa358ced1 (patch) | |
tree | f1cf86462dba1a85afd6005fca0a45b7e574c23c /rpm/init-functions-compat | |
parent | Initial commit. (diff) | |
download | postgresql-common-73e1fa4347d6c81c6e64054957ab436fa358ced1.tar.xz postgresql-common-73e1fa4347d6c81c6e64054957ab436fa358ced1.zip |
Adding upstream version 200+deb10u5.upstream/200+deb10u5upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'rpm/init-functions-compat')
-rw-r--r-- | rpm/init-functions-compat | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/rpm/init-functions-compat b/rpm/init-functions-compat new file mode 100644 index 0000000..da13596 --- /dev/null +++ b/rpm/init-functions-compat @@ -0,0 +1,12 @@ +# Functions missing in older /lib/lsb/init-functions scripts + +function_exists () { + type $1 >/dev/null 2>&1 +} + +function_exists log_daemon_msg || log_daemon_msg () { echo -n "$1:${2:+ $2}"; } +function_exists log_progress_msg || log_progress_msg () { echo -n " $1"; } +function_exists log_end_msg || log_end_msg () { if [ $1 -eq 0 ]; then echo "."; else echo "failed!"; fi; } +# this one exists, but we provide it anyway so we don't need to depend on redhat-lsb-core: +function_exists log_warning_msg || log_warning_msg () { echo "$1"; } +function_exists log_failure_msg || log_failure_msg () { echo "$1"; } |