19 lines
537 B
Bash

#!/bin/bash
backup_criinc="/mnt/backup/26097/criinc/nik/Maildir"
destination_criinc="/home/nik/Maildir"
backup_othmir="/mnt/backup/26097/othmir"
destination_othmir="/home/nik"
if [ -d "$destination_dir" ]; then
read -p "POZOR: Obstojajo podatki v direktoriju $destination_dir. Nadomestim? (da/ne) " confirm
if [ "$confirm" != "da" ]; then
echo "Obnovitev prekinjena."
exit 1
fi
fi
# rsync -av $backup_othmir/ $destination_othmir
rdiff-backup --force --restore-as-of now $backup_criinc $destination_criinc