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

Re: Multiblobs

From
HCHervé Cauwelier <herve@itaapy.com>
Date
Apr 30, 2010, 09:14 UTC
Message-ID
<4BDA9F5C.2080808@itaapy.com>
In-Reply-To
<loom.20100428T204406-308@post.gmane.org>
On 04/28/10 21:13, Sergio Callegari wrote:
Show 6 quoted lines
> If you store a structured file as a multiblob, you can use a blob for each
> uncompressed element of content.  For instance, when storing an opendocument
> file you could use a blob for manifest.xml, one for content.xml, etc... (try
> unzip -l on an odt or odp file to get an idea). When you edit your file only a
> few of these change. For instance, if we talk about a presentation, each slide
> has its own content.xml, so changing one slide only that changes.

I'll obviously let the Git experts answer you, but I can answer about OpenDocument itself.

In a presentation each slide is a <draw:page/> inside a single content.xml. So if you change one slide, the whole XML will serialize with a different SHA.

And maybe you'll add style to that slide, or probably OpenOffice.org will generate an automatic style, so styles.xml will also change. Adding an image also changes manifest.xml, along with storing the image itself. OOo will surely record the last slide displayed when closing the application, so settings.xml will change too.

So, all in all, for a single slide, 30 to 80 % of the Zip content may change.

Unless you are talking about a dedicated application to store and generate on-the-fly office documents, built on top of Git, you're better not touching the contents the user is entrusting git to store, and write a .gitattribute not to compress them in a pack.

You may also be interested in the git-bigfiles project that was mentioned last week.

http://caca.zoy.org/wiki/git-bigfiles
-- 
Hervé Cauwelier - ITAAPY - 9 rue Darwin 75018 Paris
Tél. 01 42 23 67 45 - Fax 01 53 28 27 88
http://www.itaapy.com/ - http://www.cms-migration.com
Previous: Avery PennarunNext: Avery Pennarun
Message 12 of 21 in “Multiblobs”
  1. Sergio CallegariApr 28, 2010
  2. Avery PennarunApr 28, 2010
  3. Sergio CallegariApr 28, 2010
  4. Avery PennarunApr 28, 2010
  5. Michael WittenApr 28, 2010
  6. SergioApr 28, 2010
  7. Avery PennarunApr 29, 2010
  8. Peter KreftingApr 29, 2010
  9. Avery PennarunApr 29, 2010
  10. Peter KreftingApr 30, 2010
  11. Avery PennarunApr 30, 2010
  12. Hervé CauwelierApr 30, 2010
  13. Avery PennarunApr 30, 2010
  14. Michael WittenApr 30, 2010
  15. Hervé CauwelierApr 30, 2010
  16. Geert BoschApr 28, 2010
  17. Mike HommeyApr 29, 2010
  18. Jeff KingMay 6, 2010
  19. Sergio CallegariMay 6, 2010
  20. Jeff KingMay 10, 2010
  21. Sergio CallegariMay 10, 2010

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.