summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 2b60162)
raw | patch | inline | side by side (parent: 2b60162)
author | Shawn Pearce <spearce@spearce.org> | |
Mon, 29 May 2006 07:17:18 +0000 (03:17 -0400) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Wed, 31 May 2006 06:09:02 +0000 (23:09 -0700) |
While trying to implement a pack reader in Java I was mislead by
some facts listed in this documentation as well as found a few
details to be missing about the pack header.
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
some facts listed in this documentation as well as found a few
details to be missing about the pack header.
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Documentation/technical/pack-format.txt | patch | blob | history |
index ed2decc107d374b07e9ce91fa755617790672743..0e1ffb24276027aa54c6b04fe404367f267cc07d 100644 (file)
- The header appears at the beginning and consists of the following:
- 4-byte signature
- 4-byte version number (network byte order)
+ 4-byte signature:
+ The signature is: {'P', 'A', 'C', 'K'}
+
+ 4-byte version number (network byte order):
+ GIT currently accepts version number 2 or 3 but
+ generates version 2 only.
+
4-byte number of objects contained in the pack (network byte order)
Observation: we cannot have more than 4G versions ;-) and
8-byte integers to go beyond 4G objects per pack, but it is
not strictly necessary.
- - The header is followed by sorted 28-byte entries, one entry
+ - The header is followed by sorted 24-byte entries, one entry
per object in the pack. Each entry is:
4-byte network byte order integer, recording where the