X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=builtin-add.c;h=02fe38b0c4c7c61bcc51544d1fd54c0b1641e2e8;hb=ce0bd64299ae148ef61a63edcac635de41254cb5;hp=6166f66bceb006b5ffc3834d4d77e253c7b7992e;hpb=2464294498da970de03c28310c0afa24aec4b76b;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; }