Want to make a .bat file that will compare, copy and

lokiju

Lifer
May 29, 2003
18,526
5
0
I'm pretty sure I can do most of what I need with xcopy but am not seeing a way to compare.

Basically I want to make a .bat file that I run with a scheduled task that will look at a remote network path compare it's contents to a local path and copy over whatever isn't in the local path that is in the remote path.

I also want it to delete from the local path whatever is there that is not in the remote path.

Does someone know the syntax or commands I'd need to use to accomplish this?

The .bat file will reside on a 2003 server OS.

:beer:

Edit: I totally forgot about robocoy and the /mir command.

Does exactly what I want.

Never mind! :eek: