Sunday, 15 May 2011

visual studio - TFS 2010 Prevent direct edits of Stage branch (only allow merge from Dev) -



visual studio - TFS 2010 Prevent direct edits of Stage branch (only allow merge from Dev) -

i have next scenario:

i have dev , stage branch code checked dev, , @ point changesets dev merged stage no direct edits/check-ins happen stage (beyond merges dev)

what want identify/verify no new code has been introduced straight stage branch did not originate changeset in dev.

it not appear possible secure stage (from source command perspective) allow check-ins of merges dev (since operations appear merge,edit after merge), thought create tfs check in policy attempts compare merged changes source.

i have created class derives policybase , have over-ridden evaluate method. in evaluate method, spin through this.pendingcheckin.pendingchanges.checkedpendingchanges , check .ismerge property , .serveritem property see if item in question merge , destined stage branch.

when spin through each alter however, don't see way track lineage or access parent might have originated (ie: dev branch version #).

how allow merges, no direct edits on stage branch?

the way accomplish in tfvc take ownership of merges. if merge have control. many organizations these sorts of draconian policies create automated script merge , rejects if there conflicts. way developer forced pull staging dev , resolve conflicts before requesting merge through web portal. if merge successful conducted on server single service business relationship , no coder required permissions staging of sort.

this dysfunctional. either don't trust coders, or not competent plenty work in code base.

another method might move git in tfs source control. in git merges non-editable , performed single action rather merge/edit in tfvc.

visual-studio tfs merge

No comments:

Post a Comment