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