git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH 0/3] merge -Xindex-only

From
Michael Haggerty <mhagger@alum.mit.edu>
Date
Jul 8, 2013, 15:21 UTC
Message-ID
<51DAD8F2.5070008@alum.mit.edu>
In-Reply-To
<cover.1373219466.git.trast@inf.ethz.ch>
[Resend because of address confusion in replied-to email.]
On 07/07/2013 08:00 PM, Thomas Rast wrote:
Show 12 quoted lines
> I recently looked into making merge-recursive more useful as a modular
> piece in various tasks, e.g. Michael's git-imerge and the experiments
> I made in showing evil merges.
> 
> This miniseries is the extremely low-hanging fruit.  If it makes a
> good first step for git-imerge, perhaps it can go in like this.  It's
> not a big speedup (about 2.2s vs 2.4s in a sample conflicting merge in
> git.git), but it does feel much cleaner to avoid touching the worktree
> unless actually necessary.
> 
> Otherwise it's probably not worth it just yet; for what I want to do
> with it, we need some more reshuffling of things.
Interesting.

For git-imerge, it would be nice to speed up merges by skipping the working tree updates. 10% might not be so noticeable, but every little bit helps :-)

But the killer benefit would be if git-imerge could do some of its automatic merge-testing and autofilling in the background while the user is resolving conflicts in the main index and working tree.

Is it possible to use this option with an alternate index file (e.g., via the GIT_INDEX_FILE environment variable)? Can it be made to leave other shared state (e.g., MERGE_HEAD) alone? If so, maybe it's already there.

For this feature to be useful for test merges, it would be enough to just get a retcode saying whether a given merge would succeed or conflict.

For it to be used for autofilling, it would also be necessary to be able to create a commit from the merge result in the alternate index (this would only be done when there are no conflicts). I assume this part can be done in the usual way using "git commit-tree".

Michael
-- 
Michael Haggerty
mhagger@alum.mit.edu
http://softwareswirl.blogspot.com/
Previous: Thomas RastNext: Thomas Rast
Message 6 of 15 in “merge -Xindex-only”
  1. 0/3 merge -Xindex-onlyThomas Rast, Jul 7, 2013
  2. 1/3 merge-recursive: remove dead conditional in update_stages()Thomas Rast, Jul 7, 2013
  3. 2/3 merge-recursive: untangle double meaning of o->call_depthThomas Rast, Jul 7, 2013
  4. Junio C HamanoJul 7, 2013
  5. 3/3 merge-recursive: -Xindex-only to leave worktree unchangedThomas Rast, Jul 7, 2013
  6. Michael HaggertyJul 8, 2013
  7. Thomas RastJul 8, 2013
  8. Michael HaggertyJul 9, 2013
  9. Thomas RastJul 9, 2013
  10. Michael HaggertyJul 9, 2013
  11. Thomas RastJul 9, 2013
  12. Thomas RastOct 26, 2013
  13. 1/3 merge-recursive: remove dead conditional in update_stages()Thomas Rast, Oct 26, 2013
  14. 2/3 merge-recursive: internal flag to avoid touching the worktreeThomas Rast, Oct 26, 2013
  15. 3/3 merge-recursive: -Xindex-only to leave worktree unchangedThomas Rast, Oct 26, 2013

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.