Check if config-file exists

This commit is contained in:
Milan Meduna 2020-11-05 09:27:42 +01:00
parent 2a56c7c761
commit 5838eedf1e

View file

@ -1,4 +1,11 @@
#!/bin/bash #!/bin/bash
if [[ ! -f "$1" ]]
then
echo "Config file not exists!"
exit 1
fi
if [ -z "$2" ] if [ -z "$2" ]
then then
lock_variable="/var/lock/zfs-backup-mm" lock_variable="/var/lock/zfs-backup-mm"