Re: grep(1) bug - duplicate output lines

2023-09-29 Thread Jamie Landeg-Jones
Kyle Evans wrote: > Alright, fine, be that way. :-) Try this on top of the existing patch: Sorry! I have this knack of (accidentally) stumbling upon weird-case bugs that usually don't affect anyone! :-) > https://people.freebsd.org/~kevans/grep-color-addition.diff Brilliant That all seems

Re: grep(1) bug - duplicate output lines

2023-09-29 Thread Kyle Evans
On 9/29/23 15:37, Kyle Evans wrote: On 9/29/23 13:25, Jamie Landeg-Jones wrote: Jamie Landeg-Jones wrote: Brilliant! Thanks for the quick response and fix. It works fine for me - I've not managed to break it again :-) Famous last words "grep -v" now produces duplicate lines! e.g. :

Re: grep(1) bug - duplicate output lines

2023-09-29 Thread Kyle Evans
On 9/29/23 13:25, Jamie Landeg-Jones wrote: Jamie Landeg-Jones wrote: Brilliant! Thanks for the quick response and fix. It works fine for me - I've not managed to break it again :-) Famous last words "grep -v" now produces duplicate lines! e.g. : Alright, fine, be that way. :-) Try

Re: grep(1) bug - duplicate output lines

2023-09-29 Thread Jamie Landeg-Jones
Jamie Landeg-Jones wrote: > Brilliant! Thanks for the quick response and fix. It works fine for me - > I've not managed to break it again :-) Famous last words "grep -v" now produces duplicate lines! e.g. : | % grep -v sdjdjdjd /COPYRIGHT|head | # @(#)COPYRIGHT 8.2 (Berkeley)

Re: grep(1) bug - duplicate output lines

2023-09-29 Thread Jamie Landeg-Jones
Kyle Evans wrote: > I think this is what we want: > > https://people.freebsd.org/~kevans/grep-color.diff Brilliant! Thanks for the quick response and fix. It works fine for me - I've not managed to break it again :-) > Basically, for --color with . we actually get each individual character >

Re: grep(1) bug - duplicate output lines

2023-09-27 Thread Kyle Evans
On 9/27/23 22:34, Greg 'groggy' Lehey wrote: On Wednesday, 27 September 2023 at 22:30:43 -0500, Kyle Evans wrote: On 9/27/23 21:40, Jamie Landeg-Jones wrote: When using color=always and a regex of '.' (for example), output lines are duplicated. $ grep --version grep (BSD grep, GNU compatible)

Re: grep(1) bug - duplicate output lines

2023-09-27 Thread Greg 'groggy' Lehey
On Wednesday, 27 September 2023 at 22:30:43 -0500, Kyle Evans wrote: > On 9/27/23 21:40, Jamie Landeg-Jones wrote: >> When using color=always and a regex of '.' (for example), output lines >> are duplicated. >> >> $ grep --version >> grep (BSD grep, GNU compatible) 2.6.0-FreeBSD >> >> E.G.: >> >>

Re: grep(1) bug - duplicate output lines

2023-09-27 Thread Kyle Evans
On 9/27/23 21:40, Jamie Landeg-Jones wrote: When using color=always and a regex of '.' (for example), output lines are duplicated. $ grep --version grep (BSD grep, GNU compatible) 2.6.0-FreeBSD E.G.: $ grep --color=always . /etc/fstab Cheers, Jamie I think this is what we want:

grep(1) bug - duplicate output lines

2023-09-27 Thread Jamie Landeg-Jones
When using color=always and a regex of '.' (for example), output lines are duplicated. $ grep --version grep (BSD grep, GNU compatible) 2.6.0-FreeBSD E.G.: $ grep --color=always . /etc/fstab Cheers, Jamie