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

Re: Peeling the onion

From
Junio C Hamano <junkio@cox.net>
Date
Oct 14, 2005, 08:40 UTC
Message-ID
<7vpsq8trsl.fsf@assigned-by-dhcp.cox.net>
In-Reply-To
<46a038f90510140048r30c7ec36n35f77a1ac52c4691@mail.gmail.com>
Martin Langhoff <martin.langhoff@gmail.com> writes:
> I personally don't care much for the -t option, at the moment. I do
> think that tree identity is in some contexts more important than
> commit identity, so there will be instances where you really want to
> have a canonical way to "drill down" to the tree.

I do not know how useful it would be, but the onion peeler can be told to dereference commit to tree.

$ ./git-cat-file -s 'v0.99.8^{tree}' 
6875
$ ./git-cat-file -s 'v0.99.8^{commit}' 
435
$ ./git-cat-file -t 'v0.99.8^{tree}' 
tree
$ ./git-cat-file -t 'v0.99.8^{commit}' 
commit
$ ./git-rev-parse v0.99.8 \
  v0.99.8^0 v0.99.8^{commit} \
  v0.99.8^{commit}^{tree} v0.99.8^{tree}
b041895af323bdef10cc9a718bda468ba3622bc0
91dd674e30ba0298e89c9be2657024805170c2ac
91dd674e30ba0298e89c9be2657024805170c2ac
bfd844a69bfd582d107622c27b89e9b959e89fd8
bfd844a69bfd582d107622c27b89e9b959e89fd8
Previous: Junio C Hamano
Message 41 of 41 in “Cogito: cg-clone doesn't like packed tag objects”
  1. H. Peter AnvinSep 23, 2005
  2. Petr BaudisSep 24, 2005
  3. H. Peter AnvinSep 24, 2005
  4. Junio C HamanoSep 24, 2005
  5. Petr BaudisSep 24, 2005
  6. Daniel BarkalowSep 24, 2005
  7. Junio C HamanoSep 24, 2005
  8. Petr BaudisNov 9, 2005
  9. Junio C HamanoNov 9, 2005
  10. Nick HengeveldNov 9, 2005
  11. Petr BaudisNov 9, 2005
  12. Nick HengeveldNov 10, 2005
  13. Junio C HamanoNov 9, 2005
  14. Petr BaudisSep 26, 2005
  15. Brian GerstSep 26, 2005
  16. Petr BaudisSep 26, 2005
  17. Junio C HamanoSep 26, 2005
  18. Petr BaudisSep 26, 2005
  19. Junio C HamanoSep 27, 2005
  20. Tom PrinceSep 27, 2005
  21. Junio C HamanoSep 27, 2005
  22. Junio C HamanoSep 26, 2005
  23. Petr BaudisSep 27, 2005
  24. Josef WeidendorferSep 27, 2005
  25. Petr BaudisSep 27, 2005
  26. Josef WeidendorferSep 27, 2005
  27. Junio C HamanoSep 27, 2005
  28. Linus TorvaldsSep 27, 2005
  29. Junio C HamanoSep 27, 2005
  30. Linus TorvaldsSep 27, 2005
  31. Linus TorvaldsSep 27, 2005
  32. Junio C HamanoSep 27, 2005
  33. Junio C HamanoSep 28, 2005
  34. Peeling the onionJunio C Hamano, Oct 14, 2005
  35. Sven VerdoolaegeSep 27, 2005
  36. Ryan AndersonSep 27, 2005
  37. Linus TorvaldsSep 27, 2005
  38. Ryan AndersonSep 27, 2005
  39. Linus TorvaldsSep 27, 2005
  40. Junio C HamanoSep 27, 2005
  41. Junio C HamanoOct 14, 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.