diff options
author | Junio C Hamano <gitster@pobox.com> | 2011-10-28 14:48:40 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2011-12-01 11:46:09 -0800 |
commit | 568508e76570e9ea36aad6446959424cebcf0535 (patch) | |
tree | 9b71da7197e9a084c3406d6020672dd11ac26b24 /builtin/add.c | |
parent | 6c526148644475acbc047faaeb57d42fde1f667d (diff) | |
download | git-568508e76570e9ea36aad6446959424cebcf0535.tar.gz |
bulk-checkin: replace fast-import based implementationjc/stream-to-pack
This extends the earlier approach to stream a large file directly from the
filesystem to its own packfile, and allows "git add" to send large files
directly into a single pack. Older code used to spawn fast-import, but the
new bulk-checkin API replaces it.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/add.c')
-rw-r--r-- | builtin/add.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/builtin/add.c b/builtin/add.c index c59b0c98fe..1c42900ff8 100644 --- a/builtin/add.c +++ b/builtin/add.c @@ -13,6 +13,7 @@ #include "diff.h" #include "diffcore.h" #include "revision.h" +#include "bulk-checkin.h" static const char * const builtin_add_usage[] = { "git add [options] [--] <filepattern>...", @@ -458,11 +459,15 @@ int cmd_add(int argc, const char **argv, const char *prefix) free(seen); } + plug_bulk_checkin(); + exit_status |= add_files_to_cache(prefix, pathspec, flags); if (add_new_files) exit_status |= add_files(&dir, flags); + unplug_bulk_checkin(); + finish: if (active_cache_changed) { if (write_cache(newfd, active_cache, active_nr) || |