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

Re: git merge questions

From
Don Zickus <dzickus@gmail.com>
Date
Dec 16, 2005, 21:13 UTC
Message-ID
<68948ca0512161313x5b09c65aw36570adb9495cf98@mail.gmail.com>
In-Reply-To
<7vacf0g4ga.fsf@assigned-by-dhcp.cox.net>
On 12/16/05, Junio C Hamano <junkio@cox.net> wrote:
Show 16 quoted lines
> Don Zickus <dzickus@gmail.com> writes:
>
> > Now over the course of 2.6.15 the arch/ppc64 was renamed to
> > arch/powerpc.  Fine. The merge algorithms handled all the unchanged
> > files properly.  However arch/ppc64/Kconfig was modified and the
> > merging was left unresolved.  In fact there is no file no merge
> > against (because it moved).  So 'git-ls-files -u' only shows stage 1+3
> > (no stage 2, of course).
> >
> > How do I merge those changes?  I don't know enough about all the git
> > commands to figure this out, especially how to take advantage of the
> > stage 1, 2, and 3 files.
>
> I do not work on the kernel myself so I'll probably get the
> details wrong, but I am guessing here is what you have:
>
Sorry, I should have been more specific.  How about this:
1) 2.6.14-test branch modifies arch/ppc64/Kconfig
2) master branch renames arch/ppc64/Kconfig to arch/powerpc/Kconfig
3) 2.6.14-test and master branch share a common ancestor v2.6.14
4) Need to merge change arch/ppc64/Kconfig to arch/powerpc/Kconfig

$ git ls-files -u 100644 c658650af429672267409508b02b38754c11a40f 1 arch/ppc64/Kconfig 100644 8abf1118ebbd59954d098d87679114ffda0e75cb 3 arch/ppc64/Kconfig ***Notice no stage 2

$ ls -ld arch/p* drwxrwxr-x 9 dzickus dzickus 4096 Dec 16 14:12 arch/parisc drwxrwxr-x 11 dzickus dzickus 4096 Dec 16 14:26 arch/powerpc drwxrwxr-x 15 dzickus dzickus 4096 Dec 16 14:26 arch/ppc ***Notice no ppc64 (was removed in master branch)

$ ls -ld arch/powerpc/Kconfig* -rw-rw-r-- 1 dzickus dzickus 24279 Dec 16 14:26 arch/powerpc/Kconfig ***Notice no backup or side copy of Kconfig

There were other conflicts with this merge (ones that weren't automatically resolved) but those were easily merged using vi and searching for <<<. However this particular file is providing an unusual case.

Let me know if this helps or not.

Cheers, Don

Previous: Junio C HamanoNext: Junio C Hamano
Message 3 of 9 in “git merge questions”
  1. Don ZickusDec 16, 2005
  2. Junio C HamanoDec 16, 2005
  3. Don ZickusDec 16, 2005
  4. Junio C HamanoDec 16, 2005
  5. Don ZickusDec 16, 2005
  6. Junio C HamanoDec 16, 2005
  7. Johannes SchindelinDec 16, 2005
  8. Junio C HamanoDec 17, 2005
  9. Junio C HamanoDec 17, 2005

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.