* [PATCH] t7508: avoid non-portable sed expression
@ 2013-09-14 4:47 Eric Sunshine
2013-09-14 17:50 ` Matthieu Moy
0 siblings, 1 reply; 2+ messages in thread
From: Eric Sunshine @ 2013-09-14 4:47 UTC (permalink / raw)
To: git; +Cc: Eric Sunshine, Matthieu Moy, Junio C Hamano
2556b996 (status: disable display of '#' comment prefix by default;
2013-09-06) introduced tests which fail on Mac OS X due to unportable
use of \t (for TAB) in a sed expression. POSIX [1][2] also disallows
it. Fix this.
[1]: http://pubs.opengroup.org/onlinepubs/9699919799/utilities/sed.html#tag_20_116_13_02
[2]: http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap09.html#tag_09_03_02
Signed-off-by: Eric Sunshine <sunshine@sunshineco•com>
---
This applies against 'next'.
t/t7508-status.sh | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/t/t7508-status.sh b/t/t7508-status.sh
index 7d52dbf..6fb59f3 100755
--- a/t/t7508-status.sh
+++ b/t/t7508-status.sh
@@ -61,7 +61,8 @@ test_expect_success 'status (1)' '
'
strip_comments () {
- sed "s/^\# //; s/^\#$//; s/^#\t/\t/" <"$1" >"$1".tmp &&
+ tab=' '
+ sed "s/^\# //; s/^\#$//; s/^#$tab/$tab/" <"$1" >"$1".tmp &&
rm "$1" && mv "$1".tmp "$1"
}
--
1.8.4.535.g7b94f8e
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-09-14 17:57 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-09-14 4:47 [PATCH] t7508: avoid non-portable sed expression Eric Sunshine
2013-09-14 17:50 ` Matthieu Moy
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox