Can I copy a file to the tfs 2010 build process template?

I see that there is a copyDirectory operation, but no copyFile operation. Is there a way to copy only one file from a directory?
Or maybe there is a way to remove one file from the directory?

Thank you for your help.

+6
source share
3 answers

No FileCopy action. You can: 1) develop your own custom asset, or 2) use InvokeMethod .

+4
source

You do not need to write your own activities. Instead, try using TFS Build Extensions . There is a RoboCopy workflow that you can use to copy files. There are many other very useful actions, such as email activity, ...

Follow this nice guide to change the DefaultTemplate workflow or any workflow inside the BuildProcessTemplates folder.

+4
source

I would use the InvokeProcess operation and invoke the xcopy command there with the correct arguments. See for example: http://www.ewaldhofman.nl/post/2010/11/09/Part-15-Fail-a-build-based-on-the-exit-code-of-a-console-application. aspx

+2
source

Source: https://habr.com/ru/post/910887/


All Articles