Skip to content

Commit

Permalink
t0008: avoid brace expansion
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
René Scharfe authored and Junio C Hamano committed Jan 10, 2013
1 parent 368aa52 commit 6f53fea
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions t/t0008-ignores.sh
Original file line number Diff line number Diff line change
Expand Up @@ -129,8 +129,13 @@ test_expect_success 'setup' '
one
ignored-*
EOF
touch {,a/}{not-ignored,ignored-{and-untracked,but-in-index}} &&
git add -f {,a/}ignored-but-in-index
for dir in . a
do
: >$dir/not-ignored &&
: >$dir/ignored-and-untracked &&
: >$dir/ignored-but-in-index
done &&
git add -f ignored-but-in-index a/ignored-but-in-index &&
cat <<-\EOF >a/.gitignore &&
two*
*three
Expand Down

0 comments on commit 6f53fea

Please sign in to comment.