mirror of
https://git.proxmox.com/git/libgit2
synced 2025-05-06 23:26:39 +00:00
Added creation of ref/heads/ and refs/tags/ directories.
This commit is contained in:
parent
2899093835
commit
1c2c7c0d16
@ -41,6 +41,7 @@
|
||||
|
||||
#define GIT_SYMREF "ref: "
|
||||
#define GIT_REFS_HEADS "refs/heads/"
|
||||
#define GIT_REFS_TAGS "refs/tags/"
|
||||
#define GIT_BRANCH_MASTER "master"
|
||||
|
||||
static const int default_table_size = 32;
|
||||
@ -806,6 +807,16 @@ int git_repository_init__create_structure_or_reinit(git_repository_init_results*
|
||||
if (gitfo_mkdir(temp_path, mode))
|
||||
return GIT_ERROR;
|
||||
|
||||
/* Creates the '/refs/heads/' directory */
|
||||
strcpy(temp_path + path_len, GIT_REFS_HEADS);
|
||||
if (gitfo_mkdir(temp_path, mode))
|
||||
return GIT_ERROR;
|
||||
|
||||
/* Creates the '/refs/tags/' directory */
|
||||
strcpy(temp_path + path_len, GIT_REFS_TAGS);
|
||||
if (gitfo_mkdir(temp_path, mode))
|
||||
return GIT_ERROR;
|
||||
|
||||
|
||||
/* To be implemented */
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user