GNU sed supports -E, -r, and --regexp-extended. BSD sed only supports
-r.
---
scripts/genconfig.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/scripts/genconfig.sh b/scripts/genconfig.sh
index 533df60..3887b07 100755
--- a/scripts/genconfig.sh
+++ b/scripts/genconfig.sh
@@ -144,7 +144,7 @@ genconfig > generated/Config.in || rm generated/Config.in
toys()
{
grep 'TOY(.*)' "$@" | grep -v TOYFLAG_NOFORK | grep -v "0))" | \
- sed -rn 's/([^:]*):.*(OLD|NEW)TOY\( *([a-zA-Z][^,]*) *,.*/\1:\3/p'
+ sed -En 's/([^:]*):.*(OLD|NEW)TOY\( *([a-zA-Z][^,]*) *,.*/\1:\3/p'
}
WORKING=
--
2.20.0.rc0.387.gc7a69e6b6c-goog
From 65ef85c7cb77013358c3058ed9f7ab635dcdc05a Mon Sep 17 00:00:00 2001
From: Elliott Hughes <[email protected]>
Date: Wed, 28 Nov 2018 11:57:01 -0800
Subject: [PATCH 2/2] macOS: use -E rather than -r for sed extended regular
expressions.
GNU sed supports -E, -r, and --regexp-extended. BSD sed only supports
-r.
---
scripts/genconfig.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/scripts/genconfig.sh b/scripts/genconfig.sh
index 533df60..3887b07 100755
--- a/scripts/genconfig.sh
+++ b/scripts/genconfig.sh
@@ -144,7 +144,7 @@ genconfig > generated/Config.in || rm generated/Config.in
toys()
{
grep 'TOY(.*)' "$@" | grep -v TOYFLAG_NOFORK | grep -v "0))" | \
- sed -rn 's/([^:]*):.*(OLD|NEW)TOY\( *([a-zA-Z][^,]*) *,.*/\1:\3/p'
+ sed -En 's/([^:]*):.*(OLD|NEW)TOY\( *([a-zA-Z][^,]*) *,.*/\1:\3/p'
}
WORKING=
--
2.20.0.rc0.387.gc7a69e6b6c-goog
_______________________________________________
Toybox mailing list
[email protected]
http://lists.landley.net/listinfo.cgi/toybox-landley.net