How to delete extra files on restore

Hello,

Does anyone have a script or procedure to delete extra files (files which are not present in the backup) on restore? I used this feature extensibely with Duplicacy.

There are 3 ways I can think of:

Why not just delete the whole directory and restore backup ?

mount the snapshot and use robocopy /mir

/mir can DELETE files as well as copy them, so it will work since it is the same as /e /purge

Did you find a solution for this? I, too, want to restore directories to whatever state they were in when I made the snapshot. And deleting the whole directory would use an unnecessary amount of time and bandwidth as opposed to using restore --skip-existing

It seems like using rclone sync is the best option for this, at least for me since I’m creating a repo with rclone.