Skip to content

Related improvements in future Git (based on merge-ort) #105

@krobelus

Description

@krobelus

I've been reading Elijah Newren's blog posts on optimizing git's merge implementation. To enable the optimizations, they added the new "ort" merge backend.
Crucially, it can merge without touching the working tree or index. These two commit messages are nice reads:

This sounds like we're one step closer to getting some of git-revise's features in core git.

git-rebase (and git cherry-pick) should move towards only touching the worktree when needed, as this comment suggests.
If that becomes reality one day, the main difference is conflict resolution (with git-revise using a temporary file (?).


Another difference is that git-revise never reparents a branch (i.e. it does not add new commits from upstream).
Maybe it makes sense to split git rebase into git rebase (for reparenting) and git revise (for history modification), like reset/checkout split off restore/switch. Ofc that's another discussion on the Git project.


I just discovered git merge-tree which has apparently always been able to merge without touching index/worktree; I wonder if this is powerful enough to replace our use of git merge-file. (I'm not sure what's the difference to the ort merge, probably this one doesn't detect renames etc.),
git merge-tree can't change commit messages, so it's not usable for git-revise.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions