I have a directory with many files with different names and some of them are having same contents.
The directory tree is like:
dir1/case-1.sc001
dir1/case-1.sc002
.................
dir1/case-1.sc010
dir1/case-1.sc011
..................
.............
dir1/case-1.sc998
dir1/case-1.sc999
The file may be more than 999 or less than it.
I want to keep the first files in the main directory and other files with same contents in a new directory.
Is there any workaround for this?
I tried for diff, cksum, fslint, rdfind, and fdupes
, detailes about how I executed are give below, as shown below, but all are not working in the same directory with different file names.
diff *
fslint .
rdfind .
fdupes -r
cksum case-1*