remove obsolete comment and trim unnecessary whitespace and lines

Signed-off-by: Felix Bartels <felix@host-consultants.de>
This commit is contained in:
Felix Bartels 2018-01-21 11:28:14 +01:00
parent 998687fdbe
commit 450165ed99

View file

@ -1,9 +1,6 @@
#! /bin/bash #! /bin/bash
set -uo pipefail set -uo pipefail
#backup li run
#backup li
display_usage() { display_usage() {
echo "Usage: $0 <repo> (local|monitor <host> <warning> <critical>|restic arguments)" >&2 echo "Usage: $0 <repo> (local|monitor <host> <warning> <critical>|restic arguments)" >&2
} }
@ -13,7 +10,6 @@ if [ "$#" -lt 2 ]; then
exit 1 exit 1
fi fi
TARGET=$1 TARGET=$1
ACTION=$2 ACTION=$2
RESTIC=$(which restic) RESTIC=$(which restic)
@ -35,8 +31,6 @@ check_config() {
echo "Restic binary not found" echo "Restic binary not found"
exit 1 exit 1
fi fi
} }
handle_params () { handle_params () {
@ -109,6 +103,7 @@ do_monitor () {
BACKUP_TST=$(date -d "$DATE $TIME" +"%s" ) BACKUP_TST=$(date -d "$DATE $TIME" +"%s" )
;; ;;
esac esac
NOW_TST=$(date +%s) NOW_TST=$(date +%s)
DIFF_S=`expr $NOW_TST - $BACKUP_TST` DIFF_S=`expr $NOW_TST - $BACKUP_TST`
@ -133,9 +128,5 @@ do_monitor () {
return $RET return $RET
} }
check_config $@ check_config $@
handle_params $@ handle_params $@