enable delete

This commit is contained in:
2017-10-09 11:18:26 +02:00
parent 50455b610a
commit d92fcdd6fc

View File

@@ -117,11 +117,11 @@ for fs in ${BTRFS_VOLUMES}; do
echo " " umount "$TMP_MNT"
else
sudo btrfs subvolume snapshot "${TMP_MNT}${subvol}" "${TMP_MNT}${target}${date}"
#if test -n "$del"; then
# for f in $(ls -d1 "${TMP_MNT}${target}"-* | sort -r | tail -n +"$del"); do
# sudo btrfs subvolume delete "$f"
# done
#fi
if test -n "$del"; then
for f in $(ls -d1 "${TMP_MNT}${target}"-* | sort -r | tail -n +"$del"); do
sudo btrfs subvolume delete "$f"
done
fi
fi
sudo umount "$TMP_MNT"
else