[user@notebook foobar]$ ls *.jpg|wc -l 1959 [user@notebook foobar]$ cksum * | cut -d' ' -f-2 | sort | uniq -di | wc -l 698 [user@notebook foobar]$
There are many jpg files in a directory. Many of the files are duplicates, but I can spot them out if the cksum is the same for them. Sometimes there are 2 or 3 file of the same picture.
Q: How can I delete the unneeded duplicates?
I need to leave 1 from every picture, so if there are 3 exactly same pictures with different filenames, only one of them should remain, so there will be no duplicates of the picture, how to do this?