Skip to content

Commit 6f53fea

Browse files
René Scharfegitster
authored andcommitted
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 <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 368aa52 commit 6f53fea

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

t/t0008-ignores.sh

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,8 +129,13 @@ test_expect_success 'setup' '
129129
one
130130
ignored-*
131131
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 &&
134139
cat <<-\EOF >a/.gitignore &&
135140
two*
136141
*three

0 commit comments

Comments
 (0)