xcopy equivalent?
Imported from the Apple Support Forums via the Wayback Machine 🔗
I posted this in the Leopard forum, but it appears that I was incorrect in doing that, so...
I am a long time PC user making a valiant effort to move to MAC. I am attempting to find a painless way to update a flash drive with some data that has to move between my office and home machines. There are a lot of files, but only a few change each day, and I have to make sure that an older file never overwrites a newer file with the same name.
On the PC I would simply fire up a command prompt and use the following xcopy command:
"xcopy pathdir1
. pathdir2 /s /h /r /c /d"
This would copy all of the files in dir1 to dir2, including all subdirectories (/s); including all hidden files (/h); including all read-only files (/r); continuing on, rather than erroring out, if a glitch develops (/c); and copying only files that are newer than those already in the target directory where the same file exists in both directories (/d)
I've been told that the "cp" command is what I want, but a review of the man file does not indicate anything similar to the /d parameter. Apparently some versions of the linux cp command allow a -u parameter, which seems to be similar, but OS X doesn't like that.
I need to make sure that an older file is never copied over a newer file, so the equivalent of the /d parameter is necessary.
What am I missing?
thanks...Bob
5 replies
Sign in or join Beachball Help to reply.
- 0
- 0
- 0
- 0
- 0