git-svn: delay term initialization
[git/gitweb.git] / t / t0024-crlf-archive.sh
blob4e9fa3cd68426942357d8f89ffa97ed3099e1084
1 #!/bin/sh
3 test_description='respect crlf in git archive'
5 . ./test-lib.sh
7 test_expect_success setup '
9 git config core.autocrlf true &&
11 printf "CRLF line ending\r\nAnd another\r\n" > sample &&
12 git add sample &&
14 test_tick &&
15 git commit -m Initial
19 test_expect_success 'tar archive' '
21 git archive --format=tar HEAD |
22 ( mkdir untarred && cd untarred && "$TAR" -xf - ) &&
24 test_cmp sample untarred/sample
28 test_expect_success UNZIP 'zip archive' '
30 git archive --format=zip HEAD >test.zip &&
32 ( mkdir unzipped && cd unzipped && "$GIT_UNZIP" ../test.zip ) &&
34 test_cmp sample unzipped/sample
38 test_done