t0024: style fix

t0024 has multiple command invocations on a single line, which goes against the style described in CodingGuidelines, thus fix that. Also, use the -C flag to give the destination when using $TAR, therefore, not requiring a subshell. Signed-off-by: Ghanshyam Thakkar <shyamthakkar001@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Ghanshyam Thakkar committed Jan 19, 2024 at 09:03 UTC 5ba95e0880a2486509c49b0ee47b58f1d4e95d14
1 file changed +7 -2
t/t0024-crlf-archive.sh
+7 -2
@@ -20,7 +20,8 @@ test_expect_success setup '
20 test_expect_success 'tar archive' '
21
22 git archive --format=tar HEAD >test.tar &&
23 - ( mkdir untarred && cd untarred && "$TAR" -xf ../test.tar ) &&
23 + mkdir untarred &&
24 + "$TAR" xf test.tar -C untarred &&
25
26 test_cmp sample untarred/sample
27
@@ -30,7 +31,11 @@ test_expect_success UNZIP 'zip archive' '
31
32 git archive --format=zip HEAD >test.zip &&
33
33 - ( mkdir unzipped && cd unzipped && "$GIT_UNZIP" ../test.zip ) &&
34 + mkdir unzipped &&
35 + (
36 + cd unzipped &&
37 + "$GIT_UNZIP" ../test.zip
38 + ) &&
39
40 test_cmp sample unzipped/sample
41