Hide branch close commits from hg flow

Hi!

We're using SourceTree with Mercurial to great satisfaction for our development, but there's one thing annoying me, which I wonder if it's configurable.

Problem:
If a developer has worked on a branch, completed the feature / change, merged into default (which is our release branch) and closed their working branch, there's this final dot in the flow showing that closing commit.

Desired solution:
I'd like the line merging the branch flow with the default branch line to be the final one, instead of having that branch close dot staying just above the line merging the two branches. Is this possible?

I hope I made sense there...

Thanks for great work, Atlassian.

// dim

1 answer

1 accepted

Hi Helge,

Thanks for the input. Closing branches can be confusing when it comes to looking at the graph. The graph reflects what has actually happened in terms of commits/merges/branches and so we maintain what's true to what Mercurial reports in the log. If you check out the Mercurial docs on closing a branch it states "This creates a closing changeset which typically contains no modifications to tracked files." So true to Mercurial, there is a merge commit and a close commit which can't be done in one go. There's two options in your case:

  1. Leave the branch open and let it become inactive (of course the branch will still technically be open though)
  2. Close your branch first, and then do your merge commit. This seems wrong, but for your case would be the only other option.

We wouldn't really mess with the log view to reflect something which isn't true, unfortunately Mercurial doesn't let you do a merge commit whilst closing the branch in one go.

Hope that helps

Hey, Kieran, and thanks for your answer. Yeah, it's good that SourceTree reflects the actual goings-on in Mercurial, so I'm with you there. On the next branch, I'll try closing it before and see how it looks.

Thanks!

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Oct 23, 2018 in Sourcetree

Tip from the team: configure your repos for hosting goodness!

Supported Platforms macOS Windows We recently introduced support for additional hosting services such as GitHub Enterprise, GitLab (Cloud, Community Edition, Enterprise Edition), and...

844 views 3 2
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you