tags:

views:

27

answers:

1

I have a question related to MSBuild script. my scenario is, if build fails build output should be copied into local system. if build passes, build output goes into server destination folder.

can anybody help me out. i am trying this with MSBuild not with Teambuilds.

Thanks Shanthi

A: 

If your build fails then the output will be in an unknown indeterminable state that will be of little use to you, so there is little or no point in copying it to a local location. If the build fails then the final task which copies the output to the network won't be executed, so that problem is taken care of.

If you still want to handle errors and execute certain tasks upon failure, then this page has some good suggestions. Alternatively, you may find the need to write your own task to do specifically what you want (writing tasks is very easy), this link will help you with that.

slugster