diff options
author | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-06-28 14:21:02 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-06-28 14:21:02 -0700 |
commit | a733cb606fed08130317d803956e946f73b0b88e (patch) | |
tree | 1ce2f43c1cd076ae24dcc0b6ad53a541e1f0a048 /pack.h | |
parent | d22b9290ab6de119d03154844910ae5d963b5f1f (diff) | |
download | git-a733cb606fed08130317d803956e946f73b0b88e.tar.gz |
Change pack file format. Hopefully for the last time.
This also adds a header with a signature, version info, and the number
of objects to the pack file. It also encodes the file length and type
more efficiently.
Diffstat (limited to 'pack.h')
-rw-r--r-- | pack.h | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/pack.h b/pack.h new file mode 100644 index 0000000000..08e120dca6 --- /dev/null +++ b/pack.h @@ -0,0 +1,23 @@ +#ifndef PACK_H +#define PACK_H + +enum object_type { + OBJ_NONE, + OBJ_COMMIT, + OBJ_TREE, + OBJ_BLOB, + OBJ_TAG, + OBJ_DELTA, +}; + +/* + * Packed object header + */ +#define PACK_SIGNATURE 0x5041434b /* "PACK" */ +struct pack_header { + unsigned int hdr_signature; + unsigned int hdr_version; + unsigned int hdr_entries; +}; + +#endif |