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

Re: [PATCH] Avoid rename/add conflict when contents are identical

From
Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Date
Aug 9, 2010, 21:24 UTC
Message-ID
<AANLkTi=tnWy3w1Ek+uvS+QCr4F+An4FfZcHepiTCFGAf@mail.gmail.com>
In-Reply-To
<5C4EA6C5B30E6B45A9164CB3A26A0D326F79D9AA04@azsmsx503.amr.corp.intel.com>
On Mon, Aug 9, 2010 at 21:00, Schalk, Ken <ken.schalk@intel.com> wrote:
Show 18 quoted lines
> Here's a simple sequence that generates this kind of conflict:
>
>  git init
>  echo content > fileA
>  git add fileA
>  git commit -m Initial
>  git checkout -b abranch
>  mv fileA fileB
>  git add fileB
>  rm fileA
>  ln -s fileB fileA
>  git add fileA
>  git commit -m Linked
>  git checkout master
>  git mv fileA fileB
>  git add fileB
>  git commit -m Moved
>  git merge --no-commit abranch

I don't know merge well enough to review the code in this patch, but the patch would be much better if you turned this sequence of commands (slightly altered, see t/README) into a now-passing test as part of the patch.

t/t3030-merge-recursive.sh would be the right place to add it.
Previous: Schalk, KenNext: Junio C Hamano
Message 2 of 8 in “Avoid rename/add conflict when contents are identical”
  1. Avoid rename/add conflict when contents are identicalSchalk, Ken, Aug 9, 2010
  2. Ævar Arnfjörð BjarmasonAug 9, 2010
  3. Junio C HamanoAug 13, 2010
  4. Schalk, KenAug 27, 2010
  5. Ævar Arnfjörð BjarmasonAug 28, 2010
  6. Schalk, KenAug 31, 2010
  7. Schalk, KenSep 1, 2010
  8. Junio C HamanoSep 3, 2010

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.