browse by category or date

To compare the content of two folders in Windows you can use diff command.


Normally, to compare to files you use this command:

C:\Users\hardono>diff file1.txt file2.txt

To compare two folder, use the parameter -rq:

C:\Users\hardono>diff -rq T:\ C:\Projects\Java\TMS

Below is the result’s snippet:

Only in C:\Projects\Java\TMS: .git
Files T:\checkpassword.asp and C:\Projects\Java\TMS/checkpassword.asp differ
Files T:\contact/Thumbs.db and C:\Projects\Java\TMS/contact/Thumbs.db differ
Only in T:\: crystalreportviewers10
Only in C:\Projects\Java\TMS/etrack: _notes
Files T:\etrack/trucker_pictures/Thumbs.db and C:\Projects\Java\TMS/etrack/trucker_pictures/Thumbs.db differ
Only in C:\Projects\Java\TMS/etrack/trucker_pictures: _notes
Files T:\images/Thumbs.db and C:\Projects\Java\TMS/images/Thumbs.db differ
Only in T:\invoice: testing.asp
Only in C:\Projects\Java\TMS/jobsummary: _notes
Files T:\jobsummary/daily_cargo_report.asp and C:\Projects\Java\TMS/jobsummary/daily_cargo_report.asp differ
Only in C:\Projects\Java\TMS/misc: _notes
Only in T:\misc/songs: newyearsong-old.mp3
Only in C:\Projects\Java\TMS/misc_new: _notes
Only in T:\misc_new/songs: newyearsong-old.mp3

If you receive error like below, it means you haven’t install Git.

You can download Git for Windows from

Once you’ve have installed it, don’t forget to add C:\Program Files (x86)\Git\bin or C:\Program Files\Git\bin (depending on the version you installed) to System’s Environment variable:


I hope it helps, cheers!

GD Star Rating
Compare Two Folders In Windows Using DIFF Command, 3.0 out of 5 based on 1 rating

About Hardono

Hi, I'm Hardono. I am working as a Software Developer. I am working mostly in Windows, dealing with .NET, conversing in C#. But I know a bit of Linux, mainly because I need to keep this blog operational. I've been working in Logistics/Transport industry for more than 11 years.

No Comment

Add Your Comment