提交 ab22aed3 编写于 作者: L Linus Torvalds 提交者: Junio C Hamano

Don't show gitlink directories when we want "other" files

When "show_other_directories" is set, that implies that we are looking
for untracked files, which obviously means that we should ignore
directories that are marked as gitlinks in the index.

This fixes "git status" in a superproject, that would otherwise always
report that subprojects were "Untracked files:"
Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: NJunio C Hamano <junkio@cox.net>
上级 e011054b
......@@ -375,6 +375,8 @@ static enum directory_treatment treat_directory(struct dir_struct *dir,
return recurse_into_directory;
case index_gitdir:
if (dir->show_other_directories)
return ignore_directory;
return show_directory;
case index_nonexistent:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册