Batch file compare two folders return files that aren't in one folder -


i'm trying make batch file compare 2 folders "core" , "custom" , return names of files aren't in custom.

so far have code, of taken form question on stack overflow. creates "arrays" of files in each folder. how can compare them?

@echo off setlocal enabledelayedexpansion  ::build "array" of folders set foldercnt=0 /f "eol=: delims=" %%f in ('dir /b core') (   set /a foldercnt+=1   set "folder!foldercnt!=%%f" )  ::print menu /l %%m in (1 1 %foldercnt%) echo %%m - !folder%%m! echo(  ::build "array" of folders set foldercnt=0 /f "eol=: delims=" %%f in ('dir /b custom') (   set /a foldercnt+=1   set "folder!foldercnt!=%%f" )  ::print menu /l %%n in (1 1 %foldercnt%) echo %%n - !folder%%n! echo(  pause  test.bat 

how about

echo y|xcopy /l /d core\* custom\ 

which should list files in core not in custom or different version in core?


Comments

Popular posts from this blog

linux - Does gcc have any options to add version info in ELF binary file? -

android - send complex objects as post php java -

charts - What graph/dashboard product is facebook using in Dashboard: PUE & WUE -