Way to copy only changed files?

G

Guest

Hi,

Is there a way to copy a directory w/o overwriting unchanged files?

I copy entire directories sometimes with lots of files in them. When I copy
an updated version of the same directory to another location where only a few
files have been changed the only options the copy command gives me are:

1) "Yes to All" which copies and overwrites all files whether they've been
changed or not -- that is slow
2) "No to All" which does not overwrite any changed files
3) Decide on a case by case basis. That's a hassle when copying 100s or
1000s of files

Seems like it would be a lot faster if "Yes to All" copied only changed
files and new files, and left unchanged files alone (ie. if the byte count +
timestamp are identical on source and target, do nothing and skip to the next
file).

Can this be done?

Thanks,
GettingByOk
 
P

Pegasus \(MVP\)

GettingByOk said:
Hi,

Is there a way to copy a directory w/o overwriting unchanged files?

I copy entire directories sometimes with lots of files in them. When I copy
an updated version of the same directory to another location where only a few
files have been changed the only options the copy command gives me are:

1) "Yes to All" which copies and overwrites all files whether they've been
changed or not -- that is slow
2) "No to All" which does not overwrite any changed files
3) Decide on a case by case basis. That's a hassle when copying 100s or
1000s of files

Seems like it would be a lot faster if "Yes to All" copied only changed
files and new files, and left unchanged files alone (ie. if the byte count +
timestamp are identical on source and target, do nothing and skip to the next
file).

Can this be done?

Thanks,
GettingByOk

This type of task is typically carried out in a batch file where
you have lots of "switches" to control the behaviour of the command.
Here is a typical example, consisting of exactly three lines of code.

@echo off
xcopy /s /d /y /c "c:\documents and Settings\GettingByOk\My
Documents\*.*" D:\Backup\
pause
 
C

Chris F Clark

Seems like it would be a lot faster if "Yes to All" copied only changed
files and new files, and left unchanged files alone (ie. if the byte count +
timestamp are identical on source and target, do nothing and skip to the next
file).

Can this be done?

Thanks,
GettingByOk

I use windiff, part of the MS visual studio package, to compare the
directories and then copy over only the files which are missing and/or
changed. I would bet there are some freeware windiff equivalents that
could do the same thing.

Hope this helps,
-Chris
 
H

HeyBub

GettingByOk said:
Hi,

Is there a way to copy a directory w/o overwriting unchanged files?

I copy entire directories sometimes with lots of files in them. When
I copy an updated version of the same directory to another location
where only a few files have been changed the only options the copy
command gives me are:

1) "Yes to All" which copies and overwrites all files whether they've
been changed or not -- that is slow
2) "No to All" which does not overwrite any changed files
3) Decide on a case by case basis. That's a hassle when copying 100s
or 1000s of files

Seems like it would be a lot faster if "Yes to All" copied only
changed files and new files, and left unchanged files alone (ie. if
the byte count + timestamp are identical on source and target, do
nothing and skip to the next file).

Can this be done?

Use Micros~1's "SyncToy" or "PathSync" (both free)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top