You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
At times when consulting logs, you search for a certain pattern, but you also want to see one or more lines that come just before or after each matching line in the search results, because those lines contain interesting information that may be difficult to match.
For example you may search for lines that contain "ERROR" but also want to see the 2 following lines that may contain the beginning of a stack trace, without seeing the complete stack trace in the search results.
Or you may search for lines that contain "ERROR" and be interested in the info line that comes just before the matching lines.
Or a combination of those, i.e. you'd like to see a given number of lines before and a given number of lines after the matching lines.
Being able to do something similar in klogg would be handy, I think.
The text was updated successfully, but these errors were encountered:
duke1995
changed the title
Allow to also show lines before and after the matching line
Allow to also show lines before and after each matching line
Mar 27, 2021
duke1995
changed the title
Allow to also show lines before and after each matching line
Make it possible to also show lines before and after each matching line
Mar 28, 2021
At times when consulting logs, you search for a certain pattern, but you also want to see one or more lines that come just before or after each matching line in the search results, because those lines contain interesting information that may be difficult to match.
For example you may search for lines that contain "ERROR" but also want to see the 2 following lines that may contain the beginning of a stack trace, without seeing the complete stack trace in the search results.
Or you may search for lines that contain "ERROR" and be interested in the info line that comes just before the matching lines.
Or a combination of those, i.e. you'd like to see a given number of lines before and a given number of lines after the matching lines.
grep allows to do this with the -B and -A options (and the -C option but that's just a combination of the other 2 options for convenience): GNU Grep · Invoking grep · Command-line Options · Context Line Control
Being able to do something similar in klogg would be handy, I think.
The text was updated successfully, but these errors were encountered: