X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=builtin-add.c;h=02fe38b0c4c7c61bcc51544d1fd54c0b1641e2e8;hb=efd0201684c6e9bf663811dc849590b8fe27b8b2;hp=6166f66bceb006b5ffc3834d4d77e253c7b7992e;hpb=f2054be4c4816d8c363dc867f462bc0af9031c02;p=git.git diff --git a/builtin-add.c b/builtin-add.c index 6166f66b..02fe38b0 100644 --- a/builtin-add.c +++ b/builtin-add.c @@ -8,6 +8,7 @@ #include "cache.h" #include "builtin.h" #include "dir.h" +#include "cache-tree.h" static const char builtin_add_usage[] = "git-add [-n] [-v] ..."; @@ -117,6 +118,7 @@ static int add_file_to_index(const char *path, int verbose) die("unable to add %s to index",path); if (verbose) printf("add '%s'\n", path); + cache_tree_invalidate_path(active_cache_tree, path); return 0; }