Skip to content

Commit

Permalink
Merge branch 'hv/submodule-update-nuke-submodules'
Browse files Browse the repository at this point in the history
"git add" allows adding a regular file to the path where a submodule
used to exist, but "git update-index" does not allow an equivalent
operation to Porcelain writers.
  • Loading branch information
Junio C Hamano committed Jun 28, 2012
2 parents 653111f + 242f55f commit 72fd7d8
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions builtin/update-index.c
Original file line number Diff line number Diff line change
Expand Up @@ -211,12 +211,6 @@ static int process_path(const char *path)
if (S_ISDIR(st.st_mode))
return process_directory(path, len, &st);

/*
* Process a regular file
*/
if (ce && S_ISGITLINK(ce->ce_mode))
return error("%s is already a gitlink, not replacing", path);

return add_one_path(ce, path, len, &st);
}

Expand Down

0 comments on commit 72fd7d8

Please sign in to comment.