Replace existing files in a directory. If used with the /a option, this command adds new files to a directory instead of replacing existing files.

:: To replace the destination file with the one from the source directory:
replace <path/to/file_or_directory> <path/to/destination>

:: To add files to the destination directory instead of replacing existing files:
replace <path/to/file_or_directory> <path/to/destination> /a

:: To interactively copy multiple files, with a prompt before replacing or adding a destination file:
replace <path/to/file_or_directory> <path/to/destination> /p

:: To replace even read only files:
replace <path/to/file_or_directory> <path/to/destination> /r

:: To wait for you to insert a disk before it replaces files (originally to allow inserting a floppy disk):
replace <path/to/file_or_directory> <path/to/destination> /w

:: To replace all files in subdirectories of the destination:
replace <path/to/file_or_directory> <path/to/destination> /s

:: To replace only files in the destination directory which are older than the files in the source directory:
replace <path/to/file_or_directory> <path/to/destination> /u

:: To display detailed usage information:
replace /?