We have a baseline folder and development branches in TFS. We'd like to add a policy where changes can only be merged into the baseline from a development branch and not edited directly unless you override the policy. How can we do this?
A:
You might consider limiting the security on those branches to the person(s) who would be responsible enough to do it right.
Chris Lively
2009-06-12 19:34:37
I noticed the "Change" column in the Check In window has the word "merge", not "edit" when I merge back to the baseline. Are you saying a policy can't check this value?
adam0101
2009-06-12 21:09:43
A merge is sometimes an edit, but not always. An edit is sometimes a merge, but not always. One does not imply the other.
Richard Berg
2009-06-16 15:44:50
I gave some bad information and just updated accordingly.
Chris Lively
2009-06-16 18:30:22
+2
A:
There is no way to enforce this restriction 100%. Options:
- write a checkin policy [but they can be overridden]
- write an event hook that notifies you [or takes some other action] when someone commits something that wasn't a merge
- restrict checkin permissions on the branch to trusted developers / integration managers [but they themselves would have full rights]
There's an example of a "merge only" checkin policy here: http://leon.mvps.org/Tfs/MergeOnlyPolicy.html
Richard Berg
2009-06-16 15:43:46