Jump to content
Strawberry Orange Banana Lime Leaf Slate Sky Blueberry Grape Watermelon Chocolate Marble
Strawberry Orange Banana Lime Leaf Slate Sky Blueberry Grape Watermelon Chocolate Marble

MSFN is made available via donations, subscriptions and advertising revenue. The use of ad-blocking software hurts the site. Please disable ad-blocking software or set an exception for MSFN. Alternatively, register and become a site sponsor/subscriber and ads will be disabled automatically. 

Sign in to follow this  
b-man

xcopy help

Recommended Posts

b-man    0

i use xcopy in a cmd file to backup some of my files

heres an example

XCOPY "T:\my user files" "V:\" /D /E /C /R /I /K /Y 
pause
exit

the problem is if i move/delete things in the main folder then i run my xcopy cmd file it recopies the files i have moved and doesnt delete the ones i have deleted is there a way i can set it to mirror or sync that folder?

Share this post


Link to post
Share on other sites
jaclaz    927

i use xcopy in a cmd file to backup some of my files

heres an example

XCOPY "T:\my user files" "V:\" /D /E /C /R /I /K /Y 
pause
exit

the problem is if i move/delete things in the main folder then i run my xcopy cmd file it recopies the files i have moved and doesnt delete the ones i have deleted is there a way i can set it to mirror or sync that folder?

WHAT is your "main" folder?

WHAT is your destination folder?

WHICH OS is that?

Xcopy is supposed to be eXact COPY, it misses many "sync" functionality.

Robocopy or Strarc:

http://www.ltr-data.se/opencode.html/

may be more suited.

BUT is what you are trying to do that is not clear to me, as XCOPY does have the /U switch:

http://ss64.com/nt/xcopy.html

/U           Copy only files that already exist in destination.

that may :unsure: be what you are after

jaclaz

Share this post


Link to post
Share on other sites
b-man    0

im running win7

i have a folder on my computer with the files i want to backup, being "T:\my user files", the destination is the "V:\" drive

if i moved or delete a file in T:\my user files and execute the backup to destination drive of V:\ it copies the moved file again but it still leaves it in its old location (in the backup) and if a file is deleted it doesnt delete it from the backup

the /U switch is to only update files in that directory where i want to add new ones aswell and if the files moves it then wouldnt update it anyway..

XCOPY "T:\my user files" "V:\" /D /E /C /R /I /K /Y 
pause
exit

looks like i will have to use one of those other ones you suggested

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×