Compare two folders which have many files inside contents Compare two folders which have many files inside contents unix unix

Compare two folders which have many files inside contents


To get summary of new/missing files, and which files differ:

diff -arq folder1 folder2

a treats all files as text, r recursively searched subdirectories, q reports 'briefly', only when files differ


diff -r will do this, telling you both if any files have been added or deleted, and what's changed in the files that have been modified.


I used

diff -rqyl folder1 folder2 --exclude=node_modules

in my nodejs apps.