diff --git a/t/t7501-commit.sh b/t/t7501-commit.sh
index c0288f345fb5809d8606f4d3cfaf73d24d6c7281..d3370ff7ff66240f14b8231de7ba0198e73e8deb 100755 (executable)
--- a/t/t7501-commit.sh
+++ b/t/t7501-commit.sh
test_expect_success \
"using paths with --interactive" \
"echo bong-o-bong >file &&
- ! echo 7 | git-commit -m foo --interactive file"
+ ! (echo 7 | git-commit -m foo --interactive file)"
test_expect_success \
"using invalid commit with -C" \
cat >editor <<\EOF
#!/bin/sh
-sed -e "s/a file/an amend commit/g" < $1 > $1-
-mv $1- $1
+sed -e "s/a file/an amend commit/g" < "$1" > "$1-"
+mv "$1-" "$1"
EOF
chmod 755 editor
cat >editor <<\EOF
#!/bin/sh
-sed -e "s/amend/older/g" < $1 > $1-
-mv $1- $1
+sed -e "s/amend/older/g" < "$1" > "$1-"
+mv "$1-" "$1"
EOF
chmod 755 editor