The problem is that in the second folder, the files are named very differently. I did this between a dir on my USB card and my local computer. d1 get-childitem -path dir1 -recurse d2 get-childitem -path dir2 -recurse compare-object d1 d2. If you got findutils and coreutils from here (because you don't want cygwin) and the less package (but you can use > \somepath\file instead of |less -S then notepad file etc). The first folder has duplicate files that exist in the second folder. It's mainly to compare files, but it also allows you to recursively compare folders. The /b flag means bare, which strips the directory listing down to file names only. You'll now have two text files that list the contents of each directory. Output File names, excluding some files I didn’t care about (Like. This is a bit dirty as I didn’t want the full path (harder to compare) but wanted to differentiate when I dug down. Output Folder names as Folder, and recursively dive-down. Note haven't tested the below I assume the pipe works in CMD. type 'dir /b > A.txt' into one window and 'dir /b > B.txt' into the other. Do a recursive loop through the directory structure.
0 Comments
Leave a Reply. |