Update rclone.sh

This commit is contained in:
2018-01-16 15:50:43 -05:00
parent d182f733ee
commit ae3e5c7aab

View File

@@ -33,7 +33,7 @@ function gzipVMbackups {
# create the tar and pipe into pigz for multi-threaded gzip
tar cf - "${base}" | pigz > "${dir%/}.gz"
# if the tar/gzip was successful, delete the backup directory
if [[ $? -eq 0 ]] && [[ -f "${dir%/}.gz" ]]; then
if [ $? -eq 0 ] && [ -f "${dir%/}.gz" ]; then
rm -rf "${dir}"
fi
done