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
4ea79a9d
Commit
4ea79a9d
authored
Feb 01, 2012
by
Vicent Martí
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
status: Document submodule TODOs
parent
bf0107d1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
11 deletions
+16
-11
src/status.c
+16
-11
No files found.
src/status.c
View file @
4ea79a9d
...
...
@@ -226,8 +226,12 @@ static int process_folder(
/* No op */
break
;
case
GIT_OBJ_COMMIT
:
/* TODO: proper submodule support */
break
;
default:
error
=
git__throw
(
GIT_EINVALIDTYPE
,
"Unexpected tree entry type"
);
/* TODO: How should we deal with submodules? */
return
git__throw
(
GIT_EINVALIDTYPE
,
"Unexpected tree entry type"
);
}
}
...
...
@@ -246,8 +250,9 @@ static int process_folder(
git_ignore__free
(
st
->
ignores
);
st
->
ignores
=
old_ignores
;
}
}
else
}
else
{
error
=
dirent_cb
(
st
,
NULL
);
}
if
(
tree_entry_type
==
GIT_OBJ_TREE
)
{
git_object_free
(
subtree
);
...
...
@@ -320,19 +325,19 @@ static int determine_status(
return
store_if_changed
(
st
,
e
);
}
/*
Last option, we're dealing with a leftover folder tree entry
*/
/*
Are we dealing with a subtree?
*/
if
(
tree_entry_type
==
GIT_OBJ_TREE
)
{
assert
(
in_head
&&
!
in_index
&&
!
in_workdir
);
return
process_folder
(
st
,
tree_entry
,
full_path
,
path_type
);
}
else
{
/* skip anything else we found (such as a submodule) */
if
(
in_head
)
st
->
tree_position
++
;
if
(
in_index
)
st
->
index_position
++
;
return
GIT_SUCCESS
;
}
/* We're dealing with something else -- most likely a submodule;
* skip it for now */
if
(
in_head
)
st
->
tree_position
++
;
if
(
in_index
)
st
->
index_position
++
;
return
GIT_SUCCESS
;
}
static
int
path_type_from
(
git_buf
*
full_path
,
int
is_dir
)
...
...
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