t5704: fix nonportable sed/grep usages
OS X's sed and grep would complain with (respectively) sed: 1: "/^-/{p;q}": extra characters at the end of q command grep: Regular expression too big For sed, use an explicit ; to terminate the q command. For grep, spell the "40 hex digits" explicitly in the regex, which should be safe as other tests already use this and we haven't got breakage reports on OS X about them. Signed-off-by: Thomas Rast <trast@inf.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Thomas Rast committed
Mar 6, 2012 at 15:50 UTC
0dbe6592ccbd1a394a69a52074e3729d546fe952
1 file changed
+2
-2
t/t5704-bundle.sh
+2
-2
@@ -54,8 +54,8 @@ test_expect_success 'ridiculously long subject in boundary' '
54
git bundle list-heads long-subject-bundle.bdl >heads &&
55
test -s heads &&
56
git fetch long-subject-bundle.bdl &&
57
- sed -n "/^-/{p;q}" long-subject-bundle.bdl >boundary &&
58
- grep "^-$_x40 " boundary
57
+ sed -n "/^-/{p;q;}" long-subject-bundle.bdl >boundary &&
58
+ grep "^-[0-9a-f]\\{40\\} " boundary
59
'
60
61
test_done