adrianlopezroche / fdupes

FDUPES is a program for identifying or deleting duplicate files residing within specified directories.
2.42k stars 186 forks source link

Feature request: Find all copies of a reference file in a directory tree. #69

Open Ferroin opened 7 years ago

Ferroin commented 7 years ago

It would be nice to be able to do something like: fdupes --reffile <file> <directory> And get a list of files in the directory that are duplicates of the specified file (in particular when the file is not itself in that directory).

This would be really useful when dealing with filesystem snapshots and trying to delete a file from all snapshots as well as the main filesystem (to free up space, or to just make sure it's actually gone).

allanwind commented 7 years ago

+1

My use case is slightly different. I have a directory with papers, and when I find a new interesting paper, I want to check if I already have it before adding it to my collection. The work-around is not super great, but I could move my new paper into a temporary directory then check my papers directory along with this new temporary directory. To guard against duplicates in the papers directory itself, I would need to first run a fdupes -dN on the papers directory. This ignores race conditions.