[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

How can I find identical files in a directory



Hi All

... what I found so far was this:

$ md5sum .* * | sort -ub | less
009fd9f616bab38a4fd2dda384741433  rc.spam
07ef54ec5b4352e425af6c065e5e7f50  .bashrc
07ef54ec5b4352e425af6c065e5e7f50  .bashrcdeleteit
15cc86b4a7a272d7b6aa1b43702e4395  .xinitrc
303a55356735e00975272fbe0e387cff  ntpdate.check
353cf20528b041f5538b1650b9c4a735  settimescript
3f9ab0d37cd16ec7850e6718f7d5bb33  user.action
62f07f52acc8399747f56243221cd6dc  default.action

     [ ... ]

In the example above you can see that .bashrc and .bashrcdeleteit are,
as I hope, the same files (and it'll produce an error, if there's a
directory it can't process, IINM .... )

My goal is to get easily rid of identical files on a system: With the
incantation above this can become very cumbersome and time-consuming. So
perhaps it's good to have something like the output that a
diff -s <file> <file1>
is showing, with a report along the line of that <file> and <file1> are
identical, resp. that they differ, and then grep the identical ones.

Hints?
Thanks in anticipation.

Best Regards
Wolfgang
-- 
Profile, Links: http://profiles.yahoo.com/wolfgangpfeiffer



Reply to: