start cron and enable highstate if soup exits on error

This commit is contained in:
m0duspwnens
2022-01-20 16:31:01 -05:00
parent e1757926cf
commit 01cb505338
2 changed files with 12 additions and 3 deletions

View File

@@ -407,11 +407,16 @@ set_version() {
systemctl_func() {
local action=$1
local echo_action=$1
local service_name=$2
if [[ "$echo_action" == "stop" ]]; then
$echo_action = "stopp"
fi
echo ""
echo "${action^}ing $service_name service at $(date +"%T.%6N")"
systemctl $action $service_name
echo "${echo_action^}ing $service_name service at $(date +"%T.%6N")"
systemctl $action $service_name && echo "Successfully ${echo_action}ed $service_name." || echo "Failed to $action $service_name."
echo ""
}