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

Re: How to turn off rename detection for cherry-pick?

From
Junio C Hamano <gitster@pobox.com>
Date
Aug 30, 2024, 16:14 UTC
Message-ID
<xmqq8qwet2c8.fsf@gitster.g>
In-Reply-To
<20240830003147.GA450797@coredump.intra.peff.net>
Jeff King <peff@peff.net> writes:
> though I'm not sure how DIFF_DETECT_COPIES should be handled
> ("recursive" silently downgrades it to DIFF_DETECT_RENAME).

I somehow suspect that we would want to go there to avoid overloading ourselves (and end-users) with conceptual complexity.

If we detect that the file the side branch modified was copied to create multiple files on our side (with or without modification on our end), where would we want to reapply their changes to? To the original file only? To all copies? The same story goes for the opposite direction. How should possibly different changes they made to their copies be merged back to the sole original file we have (which we may or may not have modified)? What if the both sides made copies of the same file, and now we need to shuffle NxM combination of changes? I would expect it would be a whole can of worms, which we _may_ be able to define concrete rules how we would handle each of these cases but we may have a hard time to explain in simple terms to end-users.

Previous: Junio C HamanoNext: Junio C Hamano
Message 9 of 10 in “How to turn off rename detection for cherry-pick?”
  1. Pavel RappoAug 26, 2024
  2. Pavel RappoAug 29, 2024
  3. Jeff KingAug 29, 2024
  4. Pavel RappoAug 29, 2024
  5. Jeff KingAug 30, 2024
  6. Pavel RappoAug 30, 2024
  7. Elijah NewrenAug 30, 2024
  8. Junio C HamanoAug 30, 2024
  9. Junio C HamanoAug 30, 2024
  10. Junio C HamanoAug 30, 2024

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.