John Neville
John Neville

Reputation: 424

Does anyone know a way of getting a list or number of errors before the build process is complete

Our build process deploys our product to a remote instance for testing and sends a custom email to our entire dev team notifying them if it was successful.

Right now I have a custom activity that uses the BuildDetails.CompilationStatus and the BuildDetails.TestStatus to determine if there were any errors in the build process.

Is there anyway to get the specific errors from build process?

Upvotes: 2

Views: 275

Answers (2)

John Neville
John Neville

Reputation: 424

The following code actually ended up doing what I wanted and I was able to go through each of the errors and warnings and add them to my email output.

List<IBuildError> builderrors = InformationNodeConverters.GetBuildErrors(buildDetails);
List<IBuildWarning> buildwarnings = InformationNodeConverters.GetBuildWarnings(buildDetails);

Upvotes: 1

radical
radical

Reputation: 4424

You could attach a custom msbuild logger and get all the errors/warnings/messages.

Edit:

Logging in MSBuild Build loggers

Upvotes: 0

Related Questions