diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-27 09:49:36 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-27 09:49:36 +0000 |
commit | 5ec6074f0633939fd17d94111d10c6c6b062978c (patch) | |
tree | bfaa17b5a64abc66c918e9c70969e519d9e1df8e /bundle.h | |
parent | Initial commit. (diff) | |
download | git-upstream/1%2.30.2.tar.xz git-upstream/1%2.30.2.zip |
Adding upstream version 1:2.30.2.upstream/1%2.30.2upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'bundle.h')
-rw-r--r-- | bundle.h | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/bundle.h b/bundle.h new file mode 100644 index 0000000..f9e2d1c --- /dev/null +++ b/bundle.h @@ -0,0 +1,34 @@ +#ifndef BUNDLE_H +#define BUNDLE_H + +#include "strvec.h" +#include "cache.h" + +struct ref_list { + unsigned int nr, alloc; + struct ref_list_entry { + struct object_id oid; + char *name; + } *list; +}; + +struct bundle_header { + unsigned version; + struct ref_list prerequisites; + struct ref_list references; + const struct git_hash_algo *hash_algo; +}; + +int is_bundle(const char *path, int quiet); +int read_bundle_header(const char *path, struct bundle_header *header); +int create_bundle(struct repository *r, const char *path, + int argc, const char **argv, struct strvec *pack_options, + int version); +int verify_bundle(struct repository *r, struct bundle_header *header, int verbose); +#define BUNDLE_VERBOSE 1 +int unbundle(struct repository *r, struct bundle_header *header, + int bundle_fd, int flags); +int list_bundle_refs(struct bundle_header *header, + int argc, const char **argv); + +#endif |