From a733cb606fed08130317d803956e946f73b0b88e Mon Sep 17 00:00:00 2001 From: Linus Torvalds Date: Tue, 28 Jun 2005 14:21:02 -0700 Subject: 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. --- pack.h | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 pack.h (limited to 'pack.h') 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 -- cgit v1.2.1