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

Re: [RFC] [PATCH 0/5] Implement 'prior' commit object links (and other commit links ideas)

From
Linus Torvalds <torvalds@osdl.org>
Date
Apr 25, 2006, 17:04 UTC
Message-ID
<Pine.LNX.4.64.0604250952490.3701@g5.osdl.org>
In-Reply-To
<BAYC1-PASMTP086A906CFB378AB229C2D8AEBF0@CEZ.ICE>
On Tue, 25 Apr 2006, sean wrote:
Show 5 quoted lines
> 
> It's a fair point.  But adding a separate database to augment the core 
> information has some downsides.  That is, that information isn't pulled, 
> cloned, or pushed automatically; it doesn't get to ride for free on top 
> of the core.

But the point is, we don't generally _want_ to pull, push, or clone this crud.

I for one would literally have to add code to say "if any commit we poll has this random field, I refuse to pull".

There's two ways to have true interoperability (and in a distributed system, that's the thing that matters):

 - keep on piling on the sh*t
 - keep it simple so that people know exactly what the rules are.
Guess which one I am religiously in favour of.

That's my whole point: the "rules" for this suggested "prior" or "related" field simply don't exist, and it doesn't even seem to be the case that people can agree what it _means_ in that nobody has actually explained what the thing would do and why you would use it.

If you cannot explain to the other side what a field is used for, then that field - by definition - is not useful for the other side. It will just result in confusion, because different users will have different notions of what to do with the field (if anything).

So some users might consider it to have meaning, and actually do different things when it exists. Others would ignore it entirely. Yet thirds would ignore it, but consider it a link that must exist - which would break whenever those people would interact with the people who ignore it, and think that it's superfluous.

This is why it has to have real meaning. If there are no rules, things will break. Some things will pull them, others won't, yet third things will do random things.

If you just want to have something that "follows" an archive, it's easy enough to do: have a totally separate ref, that is a real branch, but may not even contain any files at all. You can - perfectly validly - have a chain of commits where all the information is in the "free-form" text area as far as git is concerned, but where the trees are all empty.

You'll find that all git users can pull such a commit, and you can use all the normal git ops on them, and you can hide your own metadata in there. And it would still be a valid git tree - your metadata would be your private thing, and you can keep it along-side the "normal" git data, and you can have your own "extended fsck", and "git pull/push" still continues to work.

Junio does something like that with the "todo" branch, for example (it's human-readable, not automated, but that doesn't really change anything). You can do

	git ls-tree todo
	git cat-file blob todo:Porcelainistas | less -S

and in general do anything you damn well please there. WITHOUT making up any new (and unnecessary) format semantics that nobody else cares about and that don't have very well-specified meaning.

		Linus
Previous: seanNext: Andreas Ericsson
Message 30 of 63 in “Implement 'prior' commit object links”
  1. Sam VilainApr 25, 2006
  2. 1/5 add 'prior' link in commit structureSam Vilain, Apr 25, 2006
  3. Junio C HamanoApr 25, 2006
  4. 2/5 git-merge-base: follow 'prior' links to find merge basesSam Vilain, Apr 25, 2006
  5. Junio C HamanoApr 25, 2006
  6. 4/5 git-commit-tree: add support for priorSam Vilain, Apr 25, 2006
  7. 5/5 git-commit: add --prior to set prior linkSam Vilain, Apr 25, 2006
  8. 3/5 commit.c: parse 'prior' linkSam Vilain, Apr 25, 2006
  9. Sam VilainApr 25, 2006
  10. Junio C HamanoApr 25, 2006
  11. Sam VilainApr 25, 2006
  12. Jakub NarebskiApr 26, 2006
  13. Jakub NarebskiApr 26, 2006
  14. [OT] Re: [RFC] [PATCH 0/5] Implement 'prior' commit object linksJunio C Hamano, Apr 26, 2006
  15. Jakub NarebskiApr 26, 2006
  16. Junio C HamanoApr 26, 2006
  17. Jakub NarebskiApr 26, 2006
  18. Junio C HamanoApr 26, 2006
  19. Jakub NarebskiApr 26, 2006
  20. Junio C HamanoApr 26, 2006
  21. Jakub NarebskiApr 26, 2006
  22. Sam VilainApr 26, 2006
  23. Jakub NarebskiApr 25, 2006
  24. Junio C HamanoApr 25, 2006
  25. Jakub NarebskiApr 25, 2006
  26. seanApr 25, 2006
  27. Linus TorvaldsApr 25, 2006
  28. Linus TorvaldsApr 25, 2006
  29. seanApr 25, 2006
  30. Linus TorvaldsApr 25, 2006
  31. Andreas EricssonApr 26, 2006
  32. Jakub NarebskiApr 26, 2006
  33. Jakub NarebskiApr 25, 2006
  34. Linus TorvaldsApr 25, 2006
  35. Jakub NarebskiApr 25, 2006
  36. Linus TorvaldsApr 25, 2006
  37. Linus TorvaldsApr 25, 2006
  38. Jakub NarebskiApr 25, 2006
  39. seanApr 25, 2006
  40. Linus TorvaldsApr 25, 2006
  41. seanApr 25, 2006
  42. Linus TorvaldsApr 25, 2006
  43. Jakub NarebskiApr 25, 2006
  44. Linus TorvaldsApr 25, 2006
  45. Jakub NarebskiApr 25, 2006
  46. Jason RiedyApr 25, 2006
  47. seanApr 25, 2006
  48. Linus TorvaldsApr 25, 2006
  49. Junio C HamanoApr 25, 2006
  50. Linus TorvaldsApr 25, 2006
  51. Junio C HamanoApr 25, 2006
  52. Linus TorvaldsApr 25, 2006
  53. Jakub NarebskiApr 26, 2006
  54. Junio C HamanoApr 25, 2006
  55. Linus TorvaldsApr 25, 2006
  56. Jakub NarebskiApr 25, 2006
  57. Sam VilainApr 25, 2006
  58. Linus TorvaldsApr 25, 2006
  59. seanApr 25, 2006
  60. Jakub NarebskiApr 25, 2006
  61. Junio C HamanoApr 25, 2006
  62. Jakub NarebskiApr 25, 2006
  63. Jakub NarebskiApr 29, 2006

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.