|
|
Log in / Subscribe / Register

Packfiles as efficient storage

Packfiles as efficient storage

Posted Feb 12, 2026 9:39 UTC (Thu) by MrWim (subscriber, #47432)
Parent article: Evolving Git for the next decade

> Git's compression does not work well for binary files, and even small edits to such files means creating entirely new objects.

I’d have thought that pack files would be efficient at storing small changes to large files. As I understand it the format allows referring to ranges of content from existing objects (not in the same pack).

You still need to hash the whole file to name the new object, but you need to read the whole file either way to see if there are changes.

Can ‘git add’ write a pack file directly?


to post comments

Packfiles as efficient storage

Posted Feb 13, 2026 0:23 UTC (Fri) by pabs (subscriber, #43278) [Link]

They aren't very efficient even for small edits to large text files. I store my shell history in git. The text file is 51MB but the pack file is 2.2GB.


Copyright © 2026, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds