git add --intent-to-add: do not let an empty blob be committed by accident
Writing a tree out of an index with an "intent to add" entry is blocked. This implies that you cannot "git commit" from such a state; however you can still do "git commit -a" or "git commit $that_path". Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
@ -42,7 +42,7 @@ int cmd_write_tree(int argc, const char **argv, const char *unused_prefix)
|
||||
die("%s: error reading the index", me);
|
||||
break;
|
||||
case WRITE_TREE_UNMERGED_INDEX:
|
||||
die("%s: error building trees; the index is unmerged?", me);
|
||||
die("%s: error building trees", me);
|
||||
break;
|
||||
case WRITE_TREE_PREFIX_ERROR:
|
||||
die("%s: prefix %s not found", me, prefix);
|
||||
|
Reference in New Issue
Block a user