Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add three new goals that involve keeping the border commits #133

Merged
merged 1 commit into from
Jul 14, 2018

Conversation

mhagger
Copy link
Owner

@mhagger mhagger commented Jun 25, 2018

Add three new goals:

  • border
  • border-with-history
  • border-with-history2

These keep all the commits along both edges of the border of the full merge graph, but not interior merge commits. They differ in whether to also preserve history information across the "gap", like rebase vs. rebase-with-history. See the README for more information.

See #129 for some discussion of why these might be useful.

/cc @make1980

Add three new goals:

* `border`
* `border-with-history`
* `border-with-history2`

These keep all the commits along both edges of the border of the full
merge graph, but not interior merge commits. They differ in whether to
also preserve history information across the "gap", like `rebase` vs.
`rebase-with-history`. See the README for more information.
Copy link

@make1980-zz make1980-zz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for adding this functionality! My understanding is that this only reduces the number of commits for the simplify result and won't change the way how merge works. Specifically auto_expand_frontier() will always do bisection for the new goals which will potentially cause problem?

@mhagger
Copy link
Owner Author

mhagger commented Jun 26, 2018

By default, these goals use bisection. Why do you think that is a problem? It should save a lot of time if you have a bunch of commits on each branch.

But if you insist on a full imerge, I think it should be possible to do the merge using --goal=full, and then at the last step use git imerge finish --goal=border or whatever option you want.

If that doesn't answer your question, then you need to sketch a diagram so I know exactly what you're asking.

@make1980-zz
Copy link

Never mind - I guess I didn't understand how merge works when goal is not equal to full. I'll try this change out.

Copy link

@make1980-zz make1980-zz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've verified that this works well and significantly increased the performance comparing with full merge.

Thanks for introducing this!

@mhagger mhagger merged commit eb8991c into master Jul 14, 2018
@mhagger mhagger deleted the simplify-to-border branch July 14, 2018 23:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants