bug#75197: [Feature Request] Support 'grep -A' without number to show all lines after match

2024-12-30 Thread KMRH via Bug reports for GNU grep
Package: grep Severity: wishlist Dear Maintainers, I would like to request a feature enhancement for the grep tool. Feature Request Allow the command 'grep -A' (without specifying a number) to default to showing all lines after a match, instead of erroring out. This would be conceptually equiv

bug#75197: [Feature Request] Support 'grep -A' without number to show all lines after match

2024-12-30 Thread arnold
Paul Eggert wrote: > Alternatively, I suppose we could add syntax like 'grep -A Inf' to do > what's requested, where "Inf" is short for infinity. And just wait, as soon as you do that, someone will want grep -A NaN :-) :-) :-) Arnold

bug#75197: [Feature Request] Support 'grep -A' without number to show all lines after match

2024-12-30 Thread Paul Eggert
On 2024-12-30 03:37, KMRH via Bug reports for GNU grep wrote: Allow the command 'grep -A' (without specifying a number) to default to showing all lines after a match We couldn't do that as-is, as 'grep -A 1' is equivalent to 'grep -A1' and people rely on that. 'grep -A 9

bug#75197: [Feature Request] Support 'grep -A' without number to show all lines after match

2024-12-30 Thread jackson
Or, for us old farts who have been using 'sed' for a half century, if I wanted to print the lines in a file starting with the line matching a certain pattern, through the remaining lines of the file, I'd use: sed -n '/pattern/,$/p' < file Then I wouldn't have to worry whether or not the 'grep