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

Re: git bug: moved file with local unstaged changes are lost during merge

From
Junio C Hamano <gitster@pobox.com>
Date
Apr 30, 2012, 00:16 UTC
Message-ID
<7vr4v6hy5p.fsf@alter.siamese.dyndns.org>
In-Reply-To
<20120429141758.GA6500@ecki.lan>
Clemens Buchacher <drizzd@aon.at> writes:
> 2. merge_trees -> process_entry
>
> Find possible rename pairs and try to merge renames. Due to the renames,
> entries that were classified as b) above can now become of type a).

Yes, unfortunately the rename-processing part of merge-recursive is known to be broken wrt things like this. If you want to punt,

> Maybe we should disable merging with a dirty work tree altogether, until
> we have a solution that is safe to use?

this is not the way to go, as "resolve" is perfectly safe. It would make more sense to disable the rename-processing part of recursive by default, until it gets cleaned up further.

Previous: Clemens Buchacher
Message 6 of 6 in “git bug: moved file with local unstaged changes are lost during merge”
  1. Joe AngellApr 11, 2012
  2. Joe AngellApr 12, 2012
  3. Jeff KingApr 13, 2012
  4. Clemens BuchacherApr 14, 2012
  5. Clemens BuchacherApr 29, 2012
  6. Junio C HamanoApr 30, 2012

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.