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

Re: Fix interesting git-rev-list corner case

From
Linus Torvalds <torvalds@osdl.org>
Date
Jul 30, 2005, 16:18 UTC
Message-ID
<Pine.LNX.4.58.0507300913000.29650@g5.osdl.org>
In-Reply-To
<m31x5gob8k.fsf@telia.com>
On Sat, 30 Jul 2005, Peter Osterlund wrote:
Show 5 quoted lines
> 
> I have problems pulling linux kernel changes from
> 33ac02aa4cef417871e128ab4a6565e751e5f3b2 to
> b0825488a642cadcf39709961dde61440cb0731c into my local tree. At first
> I thought your patch would fix it, but it doesn't:

No, this is a merge conflict failure, and you simply have conflicts in the tree. git did everything right, it just couldn't do an automatic merge.

Show 5 quoted lines
> ERROR: Merge conflict in arch/um/os-Linux/elf_aux.c.
> ERROR: Merge conflict in arch/x86_64/kernel/smpboot.c.
> ERROR: Merge conflict in drivers/i2c/busses/i2c-mpc.c.
> ERROR: Merge conflict in include/asm-i386/bitops.h.
> ERROR: Merge conflict in kernel/sys.c.

We don't have any nice graphical tools to show these to you like BitKeeper had, although it shouldn't be fundamentally hard.

What you need to do is basically edit all those five files, and look for the conflicts (they are just like normal CVS conflicts:

	<<<<<<<
		orig-branch
		conflict-contents
	=======
		pulled-branch
		conflict-contents
	>>>>>>>>

and then you edit them to your liking until you have no more conflicts, and then you have to commit your manual resolve with

	git commit --all
which will commit the merge _and_ your manual conflict resolution.

This is something where a nice wrapper layer could do a lot better. I know there are graphical three-way merge programs available.

But core git is no worse (and in fact a _lot_ better) than CVS in this regard, so I feel that the git merge, while obviously not perfect or even very smart, is "sufficient" for what git is (ie it's up to porcelain to do anything better).

			Linus
Previous: Peter OsterlundNext: Peter Osterlund
Message 7 of 15 in “Fix interesting git-rev-list corner case”
  1. Linus TorvaldsJul 29, 2005
  2. Ryan AndersonJul 30, 2005
  3. A Large Angry SCMJul 30, 2005
  4. Linus TorvaldsJul 30, 2005
  5. Linus TorvaldsJul 30, 2005
  6. Peter OsterlundJul 30, 2005
  7. Linus TorvaldsJul 30, 2005
  8. Peter OsterlundJul 30, 2005
  9. Linus TorvaldsJul 30, 2005
  10. Peter OsterlundJul 30, 2005
  11. Linus TorvaldsJul 30, 2005
  12. Linus TorvaldsJul 30, 2005
  13. Peter OsterlundJul 30, 2005
  14. Linus TorvaldsJul 31, 2005
  15. Junio C HamanoJul 31, 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.