COPY CPY CY

Description:

   Copy a file(s). Options are argued first and include: 'O' to overwrite
   existing files and 'N' to overwrite existing files only if newer. The source
   file(s) may include wildcards. The source and destination path must be
   specified. Multiple files may be copied, based on the wildcards detected.
   Both source and destination path specifications will be used to limit the
   scope of any searches for files and creation of files. The file arguments
   must be seperated with a "TO" argument, which also helps to indicate the
   direction.

Form:

   COPY|CPY|CY [FILENAME] TO [NEW_NAME]
   Argument List:
   Argument     Description
   FILENAME     Source path, Name, placeholders and wildcards valid
   NEW_NAME     Destination path, Name, placeholders and wildcards valid

Response:

   COPY RESPONSE
      Verbose- "ERROR- [Description]\r\n" if any fatal error preventing operation, or
               "OK\r\n" to acknowledge receipt of command or
               "ERROR- [Description]\r\n" to report file operation error
      Terse-   "[NON-ZERO NUMERIC VALUE]\r\n" if any fatal error preventing operation, or
               "0\r\n" to acknowledge receipt of command or
               "[NON-ZERO NUMERIC VALUE]\r\n" to report file operation error
               "\r\n" concludes modify responses (empty line)

Examples:

   Verbose command to copy a file:
   COPY /media/hd0/media/FOOT.MPG to /media/hd0/media/TEST/ <enter>
      Response is: OK\r\n

   Verbose command to copy files matching a pattern to new directory:
   COPY FOO*.MPG to /media/hd0/media/TEST/ <enter>
      Response is: OK\r\n

   Terse command to copy a file:
   CY /media/hd0/media/FOOT.MPG to /media/hd0/media/TEST <enter>
      Response is: 0\r\n

   Terse command to copy files matching a pattern to new directory:
   COPY FOO*.MPG to /media/hd0/media/TEST/ <enter>
      Response is: OK\r\n

Notes:

NOTE: If you do not provide pathing information the first file found matching
      the name argued will be copied. The only way to guarantee the correct file
      will be copied is to provide the path given from the "DIR P" command.
NOTE: Valid wild card are '*' for any sequence of characters or '?' as a
      placeholder for any single character.
NOTE: If wildcards are used the correct pathing information MUST be supplied.

Products Supporting Command

Created By: Adtec Digital