On Fri, Mar 03, 2023 at 07:20:51PM +0800, Jialu Xu wrote:
Just got a working grep without \K, seems that it is three times more efficient than sed in my test, is it necessary to update?
grep -Poh '(?<=^ )\S+|(?<== )\S+[^\](?=$)' {} + |
-- Jialu
I just tried this and it does have better performance. Even better than your previous grep expression it seems, so I would definitely send a patch.
-- Carlos Llamas