A couple of weeks ago, I posted on an update for the Check for Warnings/Errors Check-in Policy for Visual Studio 2010 / TFS 2010. This version was posted here on the Visual Studio Gallery. Since then, I’ve received some questions about an update for the Visual Studio 2008 / TFS 2008 version of this check-in policy as the one I posted last September had an issue when checking in source code from the command line.
I have now also posted an updated version of the Check for Warnings/Errors Check-in Policy for Visual Studio 2008 / TFS 2008. If you’re still using TFS 2008 (and I’m sure a lot of you are) then you can download the updated check-in policy here.
To add this check-in policy to your Team Project:
- Download and install the Check for Compilation Warnings and Errors Check-in Policy. NOTE: Anyone checking in code will need to install the check-in policy on their local development workstations.
- Within the Team Explorer in Visual Studio 2008, right-click on the desired Team Project and select Team Project Settings->Source Control.
- Click on the Check-in Policy tab, select Check for Compilation Warnings and Error Policy and click OK.
- Click on the Edit button and select the level of Warnings and/or Errors to check for.
- Click OK and OK to close the dialog windows.
Once installed and configured, the check-in policy works like any other. You can check the Pending Changes window for violations as seen in this screen shot:
This version of the Check for Compilation Warnings and Errors Check-in Policy supports Visual Studio 2008 and Team Foundation Server 2008. The Visual Studio 2010 version is available here.