[PATCH] remote-helpers/test-bzr.sh: do not use grep \s

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Using grep "devel\s\+3:" to find at least one whitspace
is not portable on all grep versions:
Not all grep versions understand "\s" as a "whitespace".

Use a literal TAB followed by SPACE like this [	 ] instead.
The + as a qualifier for "one or more" is not a basic regular expression:
use egrep instead of grep.

Signed-off-by: Torsten Bögershausen <tboegi@xxxxxx>
---
 contrib/remote-helpers/test-hg.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/contrib/remote-helpers/test-hg.sh b/contrib/remote-helpers/test-hg.sh
index 5f81dfa..7bb81f2 100755
--- a/contrib/remote-helpers/test-hg.sh
+++ b/contrib/remote-helpers/test-hg.sh
@@ -115,7 +115,7 @@ test_expect_success 'update bookmark' '
   git push
   ) &&
 
-  hg -R hgrepo bookmarks | grep "devel\s\+3:"
+  hg -R hgrepo bookmarks | egrep "devel[	 ]+3:"
 '
 
 test_done
-- 
1.8.2.341.g543621f

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]