Thursday, November 03, 2005 1:34 AM Erwyn van der Meer

How to enfore clean build for check-in in Visual Studio Team System

The clean build policy is indeed gone from Team Foundation Server Beta 3.

If you only want to enfore that a project builds without errors before you can check-in one or more of its files, you must now use the code analysis check-in policy.

You can add a code analysis check-in policy through the menu item Team | Team Project Settings | Source Control. Go to the tab Check-in Policy and click the Add button. Select Code Analysis and click OK. Now the Code Analysis Policy Editor appears. You can deselect all of the code analysis rules and Visual Studio will still check for a succesfull build before allowing a check-in, like so:

 Screenshot of the Code Analysis Policy Editor of Visual Studio 2005 Team System (click for larger version)

Here is a screenshot of the policy violation on check-in that occurs when a project has not been build succesfully:

Screenshot of a Team System window showing a code analysis check-in policy violation when the project was not build succesfully (click for larger version)

Filed under:

# How to enfore clean build for check-in in Visual Studio Team System (part 2)

Friday, November 04, 2005 12:20 AM by Erwyn van der Meer

Code analysis settings on a project within a solution versus settings on a Team Project.

# Problem with Code Analysis in Team Architect

Thursday, November 10, 2005 1:41 AM by Erwyn van der Meer

Is the Visual Studio 2005 Team Edition for Software Architects supposed to support some form of code analysis? I ran into a problem this week with a Team Project that has a check-in policy.

# re: How to enfore clean build for check-in in Visual Studio Team System

Tuesday, June 27, 2006 8:34 AM by a

doesnt work (at least with web projects)