Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Preserving history when merging Subversion branches

Tags:

Is there any way to perform a merge with subversion 1.6 which would preserve the branch's history?

trunk:  r1 --> r2 --------------> r5 branch:          \--> r3 --> r4 / 

such as that when I merge at r4 the history will contain r3 and r4? At the moment subversion will record one merge commit with the diff between r4 and r2.

like image 778
Robert Munteanu Avatar asked Jun 12 '09 15:06

Robert Munteanu


People also ask

Does git merge preserve history?

In the Conceptual Overview section, we saw how a feature branch can incorporate upstream changes from main using either git merge or git rebase . Merging is a safe option that preserves the entire history of your repository, while rebasing creates a linear history by moving your feature branch onto the tip of main .

What happens when two branches are merged?

Merging Branches. Once you've completed work on your branch, it is time to merge it into the main branch. Merging takes your branch changes and implements them into the main branch. Depending on the commit history, Git performs merges two ways: fast-forward and three-way merge.

Does merge rewrite history?

A merge takes two or more branches, and creates a commit that interleaves the changes in all parents (resolving conflicts, as needed; the user has to decide how). git does not change history by itself.


1 Answers

What does it mean to preserve branch's history? If you want svn log and svn blame to see through merges, use option --use-merge-history or -g.

like image 72
Laurynas Biveinis Avatar answered Sep 16 '22 11:09

Laurynas Biveinis