Skip to content

Commit a101eb4

Browse files
committed
Merge branch 'hv/submodule-update-nuke-submodules' into maint
"git add" allows adding a regular file to the path where a submodule used to exist, but "git update-index" did not allow an equivalent operation to Porcelain writers. * hv/submodule-update-nuke-submodules: update-index: allow overwriting existing submodule index entries
2 parents 95c9eb8 + 242f55f commit a101eb4

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

builtin/update-index.c

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -211,12 +211,6 @@ static int process_path(const char *path)
211211
if (S_ISDIR(st.st_mode))
212212
return process_directory(path, len, &st);
213213

214-
/*
215-
* Process a regular file
216-
*/
217-
if (ce && S_ISGITLINK(ce->ce_mode))
218-
return error("%s is already a gitlink, not replacing", path);
219-
220214
return add_one_path(ce, path, len, &st);
221215
}
222216

0 commit comments

Comments
 (0)