Compare content of two folders, including subfolders

Over the years I have imported photos from iPhone to Mac and organized them in folder by month.

I now want to import all photos I have on the iPhone and compare those with the files that I’ve organized in folders over the years – if there are any missing.

Is there any tool (included in OSX or free/purchaseable) or other procedure that can compare folder content, with one folder holding the files in root and the other in many subfolders?


Terminal: diff

You can compare two folders in Terminal using the following command:

diff -rq /path/to/folder1 /path/to/folder2

To ignore folder hierarchy you can copy all the files out of a folder into a third folder, then compare these:

find /path/to/folder2 -mindepth 2 -type f -print -exec cp {} /path/to/folder3 \;

Source : Link , Question Author : Fellow Stranger , Answer Author : grg

Leave a Comment