rupweb
rupweb

Reputation: 3328

tfs autobuild format to overwrite not increment

I am trying to have the TFS build process deploy a C# executable to a remote location and overwrite the existing executable there. How can I do this? If I set the build definition Build Number Format to $(BuildDefinitionName) then I get the error:

TF42064: The build number '...' already exists for build definition

UPDATE

It's TFS 2010 so I've asked for an upgrade to TFS 2015 or later. The application is deployed by using the default build template shared below:

enter image description here

Upvotes: 0

Views: 40

Answers (1)

Cece Dong - MSFT
Cece Dong - MSFT

Reputation: 31073

It's suggested upgrade your TFS 2010 to TFS 2015 or new versions, with new build systems in new TFS, it will be much easier to delete a target folder.

In TFS 2010, you could customize your TFS build template by adding InvokeProcess activity to invoke a command line/shell, and run a script to delete folders/files.

Upvotes: 1

Related Questions