次の方法で共有


Available Check-In Policies for Team Foundation Server

Included in Visual Studio 2005 Team System:

  • Work Items
  • Code Analysis: Check-in policy can be used to control and improve the quality of code that is checked into the code base. 
  • Testing Policy

As part of the Visual Studio SDK September 2006 (can be downloaded for free):

  • Example.SimpleCheckinPolcy: Sample C# class to enforce check in comments. Demonstrates customizability of check in policies. Can be found unter:
    %ProgramFiles%\Visual Studio 2005 SDK\2006.09\VisualStudioTeamSystemIntegration\Version Control\ExtensibilityPolicySample
  • Example.ForbiddenPatternsCheckinPolicy: Sample C# project demonstrating a customizable forbidden patterns check-in policy. This sample provides the base C# project for defining a forbidden regular expression check in policy. Can be found unter:
    %ProgramFiles%\Visual Studio 2005 SDK\2006.09\VisualStudioTeamSystemIntegration\Version Control\CheckinPoliciesForbiddenPatterns

Developed by the community:

  • TFS Custom Path CheckIn Policy: The Custom Path CheckIn Policy works in concert with existing Team Foundation Server (TFS) check-in policies, providing a mechanism that allows you to specify the source control path(s) that a particular policy is allowed to act on. This will allow for example a single Team Project to have one set of Code Analysis rules for a particular folder and completely different set of rules for another folder. It would also allow for filtering what specific items the rules work on for instance enforcing a Work Item for any check-in of files ending in ".cs, .sln, .csproj" but ignore the rule for all other check-ins.
  • Time That Task VSTS Check-In Policy: Custom VSTS check-in policy that gathers hours worked on a task during each check-in. This policy requires check-in to be associated with only one task that is in an "Active" status. It also gathers the number of hours worked on the associated task incrementing the completed hours and decrementing the remaining hours. If the number of hours worked on code in check-in is greater than remaining work hours on the associated task, user will be asked to re-estimate the number or hours remaining for the task.
  • Check for Comments Check-In Policy: Doesn't need an explaination, I think... 
  • TFS - Code Comments Check-in Policy: This Team Foundation Server policy ensures that the code contains comments for classes, methods and properties before checking in it to the source control server.
  • TFS Code Review Workflow:This project is a combination of a Code Review Work Item and a Code Review Check-in Policy. The check-in policy doesn’t allow a check-in unless it has an associated Code Review work item, and that work item is set to approved. Only people in a TFS group named {Project}\Code Reviewers can set an item to approved: Code Review Work Item, Code Review Custom Check-In Policy and Code Reviewers Security Group.

Will be made available by Microsoft as Check-in Policies Pack:

  • Check-in policy granularity: there is one already in Code Gallery and what we will do is package this, change some of the UI and take out some of the complexity
  • Work-Item Associations: This is a very cool one that I hope many of you will find useful. You get to specify a query and if the associated work items by the developer are not part of the query results the check-in is blocked. This is very useful when it comes to making sure that check-ins are always associated with approved bugs.
  • Banned files: this policy allows you to specify a file extension or a regular expression in order to keep files that you don’t want out of version control. This is usually used for dll’s, build artifacts, or some website files that are automatically generated.
  • Check-in Comments: this policy gets shipped as part of the SDK. It looks at the check-in comments and makes sure it is not blank.

Do You know more? Drop me a comment or contact me.

This list will be updated as new items arrive...