mirror of
https://git.proxmox.com/git/libgit2
synced 2025-05-05 18:33:28 +00:00

The following methods have been implemented: git_reference_packall git_reference_rename git_reference_delete The library now has full support for packed references, including partial and total writing. Internal documentation has been updated with the details. Signed-off-by: Vicent Marti <tanoku@gmail.com>
38 lines
937 B
C
38 lines
937 B
C
#ifndef INCLUDE_refs_h__
|
|
#define INCLUDE_refs_h__
|
|
|
|
#include "common.h"
|
|
#include "git2/oid.h"
|
|
#include "git2/refs.h"
|
|
#include "hashtable.h"
|
|
|
|
#define GIT_REFS_DIR "refs/"
|
|
#define GIT_REFS_HEADS_DIR GIT_REFS_DIR "heads/"
|
|
#define GIT_REFS_TAGS_DIR GIT_REFS_DIR "tags/"
|
|
#define GIT_REFS_REMOTES_DIR GIT_REFS_DIR "remotes/"
|
|
|
|
#define GIT_SYMREF "ref: "
|
|
#define GIT_PACKEDREFS_FILE "packed-refs"
|
|
#define GIT_PACKEDREFS_HEADER "# pack-refs with: peeled "
|
|
#define MAX_GITDIR_TREE_STRUCTURE_PATH_LENGTH 100
|
|
|
|
struct git_reference {
|
|
git_repository *owner;
|
|
char *name;
|
|
unsigned int type;
|
|
};
|
|
|
|
typedef struct {
|
|
git_hashtable *packfile;
|
|
git_hashtable *loose_cache;
|
|
} git_refcache;
|
|
|
|
|
|
void git_repository__refcache_free(git_refcache *refs);
|
|
int git_repository__refcache_init(git_refcache *refs);
|
|
|
|
int git_reference__normalize_name(char *buffer_out, const char *name);
|
|
int git_reference__normalize_name_oid(char *buffer_out, const char *name);
|
|
|
|
#endif
|