On Sat, Nov 26, 2016 at 01:49:00PM +0000, James wrote: > I just found if I merge branch B to branch A, the two branches will become > the same. changes in branch A will gone. Is this by design? or I did > something wrong? I am using the latest Tortoise. > > > I did more than once with the instruction found online: > > In the From URL option, you should mention the branch to which you have to > merge. For example, assume that there are 2 branches branch A and branch B, > and you want to merge branch B to branch A. In TortoiseSVN, click on Merge > option and then select Merge two different trees option. In the From URL, > please mention URL of branch A and in the To URL, mention URL of branch B. > This should merge branch B to branch A without loosing any files. > > Thanks,James
What you have found online is misleading at best. TSVN's "Merge two different trees" merge compares two trees A and B, and merges the difference between them into the working copy folder which was right-clicked when initiating the merge command. It is not the "To" input field, but the working copy which determines the merge target. "From" and "To" here refer to a comparison of two tree states which yields the difference (changes) the merge should apply to the merge target. "From" and "To" do not (necessarily) refer to branches! I don't know why TSVN developers have decided to use these labels. I think they are misleading and you're not the first person I have met to be misled by them. If you want to merge branch B into branch A, check out a working copy of branch A, right-click on the root directory of this working copy, and use the "Merge a range of revisions" merge. There, specify the URL of branch B to merge from, and leave the revision range field blank (which will cause all outstanding changes to be merged, instead of just particular changes). Hope this helps you! Stefan