summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicolas Pitre <nico@fluxnic.net>2010-02-17 14:05:55 -0500
committerJunio C Hamano <gitster@pobox.com>2010-02-17 11:08:44 -0800
commit8c2ca8dd8a5d6d8beaa0a4abed0c135004eef772 (patch)
treebfc91c12c3218fd7e9e87d4051b4b8ee7e609046
parent89e0a3a131d251b5345845529d5258ab91105c9b (diff)
downloadgit-8c2ca8dd8a5d6d8beaa0a4abed0c135004eef772.tar.gz
fast-import: honor pack.indexversion and pack.packsizelimit config vars
Signed-off-by: Nicolas Pitre <nico@fluxnic.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rw-r--r--fast-import.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/fast-import.c b/fast-import.c
index d2f45b18d9..7fc98620b2 100644
--- a/fast-import.c
+++ b/fast-import.c
@@ -2876,6 +2876,17 @@ static int git_pack_config(const char *k, const char *v, void *cb)
pack_compression_seen = 1;
return 0;
}
+ if (!strcmp(k, "pack.indexversion")) {
+ pack_idx_default_version = git_config_int(k, v);
+ if (pack_idx_default_version > 2)
+ die("bad pack.indexversion=%"PRIu32,
+ pack_idx_default_version);
+ return 0;
+ }
+ if (!strcmp(k, "pack.packsizelimit")) {
+ max_packsize = git_config_ulong(k, v);
+ return 0;
+ }
if (!strcmp(k, "core.bigfilethreshold")) {
long n = git_config_int(k, v);
big_file_threshold = 0 < n ? n : 0;