Deploying a check-in policy
The deployment is also really simple and basically requires just a single registry addition. Open regedit.exe
and navigate to HKEY_CURRENT_USER\SOFTWARE\Microsoft\VisualStudio\14.0\TeamFoundation\SourceControl
. In this key, you will need to add a new key named Checkin Policies, and in that key, you will have to create a new string value. The string value name needs to be the value of your project's output assembly, which in the case of the sample code is BigChangesPolicy. Then, you need to set the value of this string to the full path to your assembly, which will be the full path to BigChangesPolicy.dll
in the case of the sample. This should look something like what is shown in the following screenshot:
On the left, you can see the Checkin Policies key that we added, and then we have the string value pointing to our policy in the panel on the right.