using xcopy, but excluding one directory
Posted on 2004-04-02
I have a batch script where I want to xcopy the contents of my Y drive to my X drive, but I want to exclude Y:\FremontTCM, which is a directory with a bunch of subdirectories and files. The following command:
xcopy /e /exclude:y:\fremonttcm y:\* x:\*
does not work. I know that the /exclude must have a filename to read from. What do I need to do here to get this to work?