Nick
Nick

Reputation: 9373

change check-in setting for entire project

We have a TFS server setup with three projects. Recently we wanted to change TFS so that code checkins had to have a Work Item Number associated with it. I was able to accomplish this by:

In Visual Studio

Team -> Team Project Settings -> Source Control

Then select checkin policy tab and add "Require associated work items."

Source

The problem is that it only seemed to work for one of the three (the first one) projects. I've tried Team -> Team Project Collection Settings but there is no option for the checkin policy.

I've also tried highlighting the individual project I wanted to change the check in policy but they all seem to show that the checkin policy has been setup correctly for requiring a work item with code checkin.

How can I change the settings that all the projects on the TFS server have the same checkin policy?

Upvotes: 0

Views: 1181

Answers (1)

Mehmet Aras
Mehmet Aras

Reputation: 5374

Check-in policies are set per team project. There is no global meaning collection or server level way of setting and enforcing check-in policies on all of existing and future team projects. You will need to add appropriate check-in policies for each and every team project you need using the project level source control setting in Team Explorer. You can also use TFS client SDK to automate that process to iterate all or some of the existing team projects and add check-in policies. Another option is to take advantage of TFS server side events to get notified when a new team project is created and add check-in policies in response in case of automating the configuration of check-in policies for newly created team projects.

Team Foundation Server Event Service

Upvotes: 3

Related Questions