Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
git2
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
git2
Commits
8ea2c83b
Commit
8ea2c83b
authored
Dec 20, 2010
by
nulltoken
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added creation of 'objects/info' and 'objects/pack' directories.
parent
2e29957a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
7 deletions
+8
-7
src/repository.c
+8
-7
No files found.
src/repository.c
View file @
8ea2c83b
...
...
@@ -35,7 +35,8 @@
#define GIT_DIR "/.git/"
#define GIT_OBJECTS_DIR "objects/"
#define GIT_REFS_DIR "refs/"
#define GIT_OBJECTS_INFO_DIR "objects/info/"
#define GIT_OBJECTS_PACK_DIR "objects/pack/"
#define GIT_REFS_HEADS_DIR "refs/heads/"
#define GIT_REFS_TAGS_DIR "refs/tags/"
...
...
@@ -786,19 +787,19 @@ int repo_init_structure(repo_init *results)
if
(
repo_init_createhead
(
temp_path
)
<
GIT_SUCCESS
)
return
GIT_ERROR
;
/* Creates the '/objects/' directory */
strcpy
(
temp_path
+
path_len
,
GIT_OBJECTS_DIR
);
if
(
gitfo_mkdir
(
temp_path
,
mode
))
/* Creates the '/objects/
info/
' directory */
strcpy
(
temp_path
+
path_len
,
GIT_OBJECTS_
INFO_
DIR
);
if
(
gitfo_mkdir
_recurs
(
temp_path
,
mode
))
return
GIT_ERROR
;
/* Creates the '/
refs
/' directory */
strcpy
(
temp_path
+
path_len
,
GIT_
REFS
_DIR
);
/* Creates the '/
objects/pack
/' directory */
strcpy
(
temp_path
+
path_len
,
GIT_
OBJECTS_PACK
_DIR
);
if
(
gitfo_mkdir
(
temp_path
,
mode
))
return
GIT_ERROR
;
/* Creates the '/refs/heads/' directory */
strcpy
(
temp_path
+
path_len
,
GIT_REFS_HEADS_DIR
);
if
(
gitfo_mkdir
(
temp_path
,
mode
))
if
(
gitfo_mkdir
_recurs
(
temp_path
,
mode
))
return
GIT_ERROR
;
/* Creates the '/refs/tags/' directory */
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment