[Bug 191086] grep(1) and bsdgrep(1) do not recognize [[:<:]] and [[:>:]]

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Mon Jan 23 14:50:10 UTC 2017


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=191086

--- Comment #2 from weeks at iastate.edu ---
OK. It's interesting to note that OS X 10.11.6, which also uses bsdgrep, does
support the '[[:<:]]' and '[[:>:]]' bracket expressions:

$ uname -srv
Darwin 15.6.0 Darwin Kernel Version 15.6.0: Mon Jan  9 23:07:29 PST 2017;
root:xnu-3248.60.11.2.1~1/RELEASE_X86_64
$ type grep
grep is a tracked alias for /usr/bin/grep
$ grep --version
grep (BSD grep) 2.5.1-FreeBSD
$ printf 'foobar\nfoo bar\nbaz' | grep 'foo[[:>:]]'
foo bar
$ printf 'foobar\nfoo bar\nbaz' | grep '[[:<:]]bar'
foo bar

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-bugs mailing list