t3404: fix quoting of redirect for some versions of bash
authorCharles Bailey <cbailey32@bloomberg.net>
Wed, 2 Dec 2015 20:50:07 +0000 (20:50 +0000)
committerJunio C Hamano <gitster@pobox.com>
Fri, 4 Dec 2015 22:05:18 +0000 (14:05 -0800)
As CodingGuidelines says, some versions of bash errors out when
$variable substitution is used as the target for redirection without
being quoted (even though POSIX may not require such a quote).

Signed-off-by: Charles Bailey <cbailey32@bloomberg.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t3404-rebase-interactive.sh
index 88d7d5358ac37ce01c68a7e04f050e843acc1989..01701aa7a7f855639b422ad6d008ef041a37b3f9 100755 (executable)
@@ -1213,7 +1213,7 @@ test_expect_success 'tabs and spaces are accepted in the todolist' '
                # Turn single spaces into space/tab mix
                sed "1s/ /      /g; 2s/ /  /g; 3s/ /    /g" "$1"
                printf "\n\t# comment\n #more\n\t # comment\n"
-       ) >$1.new
+       ) >"$1.new"
        mv "$1.new" "$1"
        EOF
        test_set_editor "$(pwd)/add-indent.sh" &&