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

Working with git binary stream

From
anatoly techtonik <techtonik@gmail.com>
Date
Aug 9, 2021, 16:12 UTC
Message-ID
<CAPkN8xJqqnJfdUM5fEEMA00JoKsFcqnQo--_qbCLAx1qXSrgdQ@mail.gmail.com>
Hi.

In https://lore.kernel.org/git/CAPkN8xK7JnhatkdurEb16bC0wb+=Khd=xJ51YQUXmf2H23YCGw@mail.gmail.com/T/#u it became clear that it is impossible to make fast-export followed by fast-import to get identical commit hashes for the resulting repository (try https://github.com/simons-public/protonfixes). It is also impossible to detect which commits would be altered as a result of this operation. Because fast-export/import does some implicit commit normalization, fixing that probably requires too much effort.

As an alternative it appeared that that theres is also a "git binary stream" log that is produced by

git cat-file --batch --batch-all-objects

Is there a way to reconstruct the repository given that stream? Is there documentation on how to read it?

-- 
anatoly t.
Next: Jeff King
Message 1 of 3 in “Working with git binary stream”
  1. anatoly techtonikAug 9, 2021
  2. Jeff KingAug 9, 2021
  3. Elijah NewrenAug 10, 2021

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.