Making a TFS Branch Read-Only

前端 未结 6 1911
傲寒
傲寒 2020-12-16 09:22

We are trying to follow the branching strategy from the TFS Branching Guide and have reached the point where we have made a branch representing a release, which should now b

6条回答
  •  旧巷少年郎
    2020-12-16 09:51

    Right-click the branch in the Source Control Explorer, and select the Lock... option

    EDIT: This seems to get missed a lot when people are finding this so I'll make it more obvious.

    Locks appear as a "pending change" for the person who locked the item. As long as the lock is in effect, it will appear as a pending change. When a commit is made of that pending change, the lock is released. While the lock is in effect, the locked branch is effectively read-only, since (to simplify) the locker is the only user who can make commits. The act of committing is what releases any locks on the branch.

    h/t @AakashM for pointing that out in the comments

提交回复
热议问题