Search for duplicate files across two folders
It can often be useful to look for duplicate files across two folders, where one of the folders has the best and most complete data, and the other folder has partial or incomplete data.
One possible real-world scenario: I have a desktop and a laptop that each have a copy of some files. One day, I'll do some work on my laptop, changing a few files, and later do some work on my desktop, and change a few other files.
I've also renamed several files, so I can't easily use a diff tool to see what has changed. How can I merge the work together, to get one directory that has all of the latest files?
First I'll copy everything onto one computer, into the directories
ben_from_laptop
andben_from_desktop
. The two directories are mostly the same, I'll try to find the differences.I'll choose one of the directories to hold the result. So I'll rename
ben_from_desktop
toben_merged
Open labs_coordinate_pictures.
From the Files menu, choose 'Search for duplicate files in two folders...'
- I'll type the paths and click 'Start...'
- Duplicate files are now shown. I can view more information about a file, like its exact size and sha-256 hash, by selecting a file and choosing File->Show File Details.
Every file in the list is a duplicate. So I'll select all files in the list, and click "Delete on Right", and confirm that I want to delete these files. (An asterisk will be shown to the left of the filename after deleting a file.)
Now I'll exit out of labs_coordinate_pictures -- every file that still exists in
ben_from_laptop
is a non-unique one that I should probably keep. I can now go through the few remaining files inben_from_laptop
and move them intoben_merged
.
Back