t0008: avoid brace expansion
Brace expansion is a shell feature that's not required by POSIX and not supported by dash nor NetBSD's sh. Explicitly list all combinations instead. Also avoid calling touch by creating the test files with a redirection instead, as suggested by Junio. Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx> Signed-off-by: Junio C Hamano <gitster@pobox.com>
René Scharfe committed
Jan 10, 2013 at 22:24 UTC
6f53feac95f35d470789348c051f6cee93449642
1 file changed
+7
-2
t/t0008-ignores.sh
+7
-2
@@ -129,8 +129,13 @@ test_expect_success 'setup' '
129
one
130
ignored-*
131
EOF
132
- touch {,a/}{not-ignored,ignored-{and-untracked,but-in-index}} &&
133
- git add -f {,a/}ignored-but-in-index
132
+ for dir in . a
133
+ do
134
+ : >$dir/not-ignored &&
135
+ : >$dir/ignored-and-untracked &&
136
+ : >$dir/ignored-but-in-index
137
+ done &&
138
+ git add -f ignored-but-in-index a/ignored-but-in-index &&
139
cat <<-\EOF >a/.gitignore &&
140
two*
141
*three