It could be useful to copy files either before or after the generation process. To achieve this, the copy command line can be used to copy files using the "Run program" build action. As it needs to be run from a command prompt, the cmd.exe program needs to be run with the "/C" arguments:
Action property |
Value |
Description |
File path |
cmd.exe |
Run a command prompt |
Arguments |
/C copy "SOURCE_PATH" "DESTINATION_PATH" |
The /C argument carries out the copy command and terminates. SOURCE_PATH is the source file's path. It can be absolute, or relative to the WorkingDirectory property. DESTINATION_PATH is the source file's path. It can be absolute, or relative to the WorkingDirectory property. |
Working directory |
WORKING_DIRECTORY_PATH |
Full path of the current directory for the process. If not specified, it will be set to the current build's output directory. |