1833652 Members
3797 Online
110062 Solutions
New Discussion

Re: Directory comparison

 
SOLVED
Go to solution
Carlo Henrico_1
Regular Advisor

Directory comparison

How would I go about comparing the contents of two directories to one another?

I have tried this:

ls -R /directory1/*.pc -exec cmp -s /directory1/{} /directory2/{}
and variations without any success.

Any help please?
Live fast, die young - enjoy a good looking corpse!
2 REPLIES 2
Andreas Voss
Honored Contributor
Solution

Re: Directory comparison

Hi,

try the command

dircmp

See also 'man dircmp'

Regards
federico_3
Honored Contributor

Re: Directory comparison

Another way could be the following:

diff -r DIR1 DIR2


federico