From: Junio C Hamano Date: Wed, 13 Jul 2016 18:24:18 +0000 (-0700) Subject: Merge branch 'jk/big-and-future-archive-tar' X-Git-Tag: v2.10.0-rc0~120 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/7a23f7367d1a9946ff151d1491a3a73de43b64c3?hp=-c Merge branch 'jk/big-and-future-archive-tar' "git archive" learned to handle files that are larger than 8GB and commits far in the future than expressible by the traditional US-TAR format. * jk/big-and-future-archive-tar: archive-tar: drop return value archive-tar: write extended headers for far-future mtime archive-tar: write extended headers for file sizes >= 8GB t5000: test tar files that overflow ustar headers t9300: factor out portable "head -c" replacement --- 7a23f7367d1a9946ff151d1491a3a73de43b64c3 diff --combined t/t9300-fast-import.sh index 74d740de41,38a06aaafc..2e0ba3ebd8 --- a/t/t9300-fast-import.sh +++ b/t/t9300-fast-import.sh @@@ -7,23 -7,6 +7,6 @@@ test_description='test git fast-import . ./test-lib.sh . "$TEST_DIRECTORY"/diff-lib.sh ;# test-lib chdir's into trash - # Print $1 bytes from stdin to stdout. - # - # This could be written as "head -c $1", but IRIX "head" does not - # support the -c option. - head_c () { - perl -e ' - my $len = $ARGV[1]; - while ($len > 0) { - my $s; - my $nread = sysread(STDIN, $s, $len); - die "cannot read: $!" unless defined($nread); - print $s; - $len -= $nread; - } - ' - "$1" - } - verify_packs () { for p in .git/objects/pack/*.pack do @@@ -52,7 -35,6 +35,7 @@@ echo "$@" ### test_expect_success 'empty stream succeeds' ' + git config fastimport.unpackLimit 0 && git fast-import response && - head_c $size >blob <&3 && + test_copy_bytes $size >blob <&3 && read newline <&3 && cat <<-EOF && @@@ -2524,7 -2506,7 +2507,7 @@@ test_expect_success PIPE 'R: print blo EOF read blob_id type size <&3 && - head_c $size >actual <&3 && + test_copy_bytes $size >actual <&3 && read newline <&3 && echo @@@ -2559,7 -2541,7 +2542,7 @@@ test_expect_success PIPE 'R: print stag echo "cat-blob $to_get" && read blob_id type size <&3 && - head_c $size >actual <&3 && + test_copy_bytes $size >actual <&3 && read newline <&3 && echo deleteall @@@ -2691,7 -2673,6 +2674,7 @@@ test_expect_success 'R: blob bigger tha echo >>input && test_create_repo R && + git --git-dir=R/.git config fastimport.unpackLimit 0 && git --git-dir=R/.git fast-import --big-file-threshold=1