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

Re: git versus CVS (versus bk)

From
JBJoel Becker <joel.becker@oracle.com>
Date
Oct 31, 2005, 19:50 UTC
Message-ID
<20051031195010.GM11488@ca-server1.us.oracle.com>
In-Reply-To
<Pine.LNX.4.64.0510310804400.27915@g5.osdl.org>
On Mon, Oct 31, 2005 at 08:18:49AM -0800, Linus Torvalds wrote:
Show 5 quoted lines
> With git (or with BK, or any truly decentralized model), you just make 
> your own repo, do your development there, and you never need to ask for 
> permissions from the central repo people. If the development works out, 
> you just ask people to merge back. And if it doesn't, you don't even have 
> to tell people what a total failure you were.
	Actually, Linus, this provokes a question I've always wanted the
answer to.  I'm well aware of the centralized/distributed stuff you are
discussing, but there is policy regarding the distributed merges I've
never been quite clear on.
	When one does a feature branch, one creates a "throw-away"
repository.  They work on the feature, and when they are done, they
pull/push back to the main repository.  This pattern is pretty much
identical in both centralized in distributed environments, even if the
nuts-and-bolts are different.
	In the CVS/Subversion world, this merge becomes a single commit
on the "main" line of development ("trunk", or whatever you call it).
The merge has no concept of the steps taken to create the change, just
the actual patch.  This has the disadvantage that you have to work hard
in the branch namespace to find the actual steps taken (the working
repository for the feature), but the advantage that a quick look does
not have to wade through fits and starts as the feature takes shape.
	In the distributed world, a pull of the "feature" repository
pulls in all changes - the full history of the work.  This includes
aborted tries, rewritten pieces, bug fixes, etc.  Here, the main
repository has the detritus of the development process, but that also
contains the full context of the work.  It goes against your claim that:
> So with the distributed model, you don't have to publicly humiliate 
> yourself when you do something stupid. Similarly, you don't have to 
because that history will contain all your something stupids, plus your
fixes for them.
	But that's not how the kernel and git appear to work.  Many
developers have popularized dropping that context.  They take their
working repository, diff it against your mainline repository, and then
create a new repository that is merely your mainline plus one commit,
the patch of their changes.
	This violently breaks the model of "work in a new repository,
then have it pulled into the 'main' repository."  It has no real support
in the git/cogito command space (that I know of).  It does, however,
leave all the intermediate commits out of your tree, with only a feature
commit remaining.
	Where do you stand on this?  Would you rather see the full
history pulled?  Do you prefer the one-clean-patch approach?  If so, is
there any way to get a cogito/git command for it (git-pull-as-one?)?
Joel
-- 
"Drake!  We're LEAVING!"

Joel Becker
Principal Software Developer
Oracle
E-mail: joel.becker@oracle.com
Phone: (650) 506-8127
Previous: Linus TorvaldsNext: Martin Langhoff
Message 12 of 61 in “git versus CVS (versus bk)”
  1. waltOct 31, 2005
  2. Martin LanghoffOct 31, 2005
  3. H. Peter AnvinOct 31, 2005
  4. Linus TorvaldsOct 31, 2005
  5. Johannes SchindelinOct 31, 2005
  6. Linus TorvaldsOct 31, 2005
  7. wa1ter@myrealbox.comOct 31, 2005
  8. Randal L. SchwartzOct 31, 2005
  9. waltOct 31, 2005
  10. Daniel BarkalowNov 1, 2005
  11. Linus TorvaldsNov 1, 2005
  12. Joel BeckerOct 31, 2005
  13. Martin LanghoffOct 31, 2005
  14. Joel BeckerOct 31, 2005
  15. Petr BaudisNov 1, 2005
  16. Joel BeckerNov 1, 2005
  17. Petr BaudisNov 1, 2005
  18. Petr BaudisNov 7, 2005
  19. Josef WeidendorferNov 8, 2005
  20. Petr BaudisNov 8, 2005
  21. Randal L. SchwartzNov 1, 2005
  22. Linus TorvaldsNov 1, 2005
  23. Randal L. SchwartzNov 1, 2005
  24. Linus TorvaldsNov 1, 2005
  25. Junio C HamanoNov 1, 2005
  26. Junio C HamanoOct 31, 2005
  27. Joel BeckerOct 31, 2005
  28. Linus TorvaldsOct 31, 2005
  29. Junio C HamanoOct 31, 2005
  30. Joel BeckerOct 31, 2005
  31. Junio C HamanoNov 1, 2005
  32. Joel BeckerNov 1, 2005
  33. Martin LanghoffNov 1, 2005
  34. Joel BeckerNov 1, 2005
  35. Linus TorvaldsNov 1, 2005
  36. Petr BaudisNov 1, 2005
  37. Catalin MarinasNov 1, 2005
  38. Theodore Ts'oNov 1, 2005
  39. hgmq vs. StGITPetr Baudis, Nov 1, 2005
  40. Catalin MarinasNov 1, 2005
  41. Petr BaudisNov 1, 2005
  42. Catalin MarinasNov 1, 2005
  43. Chuck LeverNov 1, 2005
  44. Chris MasonNov 1, 2005
  45. Catalin MarinasNov 1, 2005
  46. Chris MasonNov 1, 2005
  47. Catalin MarinasNov 1, 2005
  48. Chris MasonNov 2, 2005
  49. Catalin MarinasNov 5, 2005
  50. Petr BaudisNov 9, 2005
  51. Pavel MachekNov 10, 2005
  52. Catalin MarinasNov 10, 2005
  53. Chris MasonNov 1, 2005
  54. Linus TorvaldsNov 1, 2005
  55. Catalin MarinasNov 1, 2005
  56. Catalin MarinasNov 1, 2005
  57. Chris MasonNov 1, 2005
  58. Catalin MarinasNov 1, 2005
  59. Daniel BarkalowNov 1, 2005
  60. Linus TorvaldsOct 31, 2005
  61. wa1ter@myrealbox.comOct 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.