[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Visualize when two branches have been merged

From: Stefan Sperling <stsp_at_elego.de>
Date: Sat, 2 Jul 2016 13:52:05 +0200

On Sat, Jul 02, 2016 at 09:18:58AM +0200, Olof wrote:
> Hi
>
> The only feature I'm really missing with SVN is the ability show in
> revision graphs when two branches have been merged. This applies to both
> the command line client and Tortoise. This feature is quite common in
> version management and is very useful so why doesn't SVN have it? I've
> googled some and found this
> http://stackoverflow.com/questions/918638/tortoisesvn-revision-graph-merge-line-connected-back-to-trunk
> discussion. However I don't agree with the most popular answer (SVN can't
> guarantee that such a visualization would show the truth since commits are
> done in working copies).

I suppose you meant to say "merges are done in working copies".

And I agree that this argument is missing the point. It claims that because
a merge may select just a subset of changes committed in a particular revision,
drawing a "line" to indicate a merge commit would be misleading since not
all changes from the revision were merged.
But that is the case for every version control system since merge commits
are never a 1:1 mapping of changes, e.g. due to conflict resolution.
The misconception seems to be that a conceptual 'merge arrow' implied
a 1:1 mapping of changes, but it does not.

> To me a line in revision graph showing when two
> branches are merged would be just a visual representation of the already
> existing svn:mergeinfo. I can select to "show merged versions" in the log -
> isn't that just a textual representation of the graph I looking for?
>
> // Olof Wolgast

Yes, it should be possible to implement such a feature.
Would you like to work on this? We'll need someone in a position to have
a need for this feature and the time and skills to make it happen.
I would support this effort if such a person showed up.

The svn mergeinfo command already shows a graph based on mergeinfo. But that's
not the information display you're looking for, assuming you're looking for an
equivalent to a holistic view similar to 'git log --graph', while the mergeinfo
command shows information about the relative state of just two branches:

$ svn mergeinfo ^/subversion/branches/authzperf
    youngest common ancestor
    | last full merge
    | | tip of branch
    | | | repository path

    1613052 1751050
    | |
       --| |------------ subversion/branches/authzperf
      / /
     / /
  -------| |------------ subversion/trunk
              | |
              1714639 WC
$
Received on 2016-07-02 13:52:21 CEST

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.