简体   繁体   中英

TFS2013 Merging of branch

We have a simple branch process where we have a Main branch which is meant to be the source code used in production. We also have one or more branches from Main which are development branches. We have emergency fixes that go into Main but may not be in one or more of the development branches. From time to time, and especially just before we promote a development branch to Main we merge from Main to the development branch to make sure everything from Main is in the branch. This time it was all there so no action was necessary. We then merged from the development branch to Main, naturally it identified all the files we had changed in the development branch, but it also came up with a small number of conflicts. Now as we had just successfully merged from Main to the branch I did not expect this. Investigation showed the following history for one of the files that had a conflict.

In Main

在此处输入图片说明

In development branch

在开发部门

It seemed a fix was made in the development branch (10917) and then merged to Main (11090). For some reason when we merge down to the branch the previous merge up (11090) is not detected and so is shown as a conflict when we try and merge to Main. In practice the code in both branches is the same but it causes extra work with us having to investigate changes that are not there.

Can not see why this did not merge down? Is our process at fault?

I think this is caused by you didn't get latest of main branch before you try to merge to development branch. Make sure you have get latest both of main and development branch before the merge.

Next time, you can directly merge specific changest, you can select selected changesets then choose 11090.

在此处输入图片说明

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM