I am trying to search a file for a pattern and if the it is found I want to see the line and 10 more lines of the result.
so far I have
grep -n pattern file | cut -d: f1
now not sure how to use this out put to do the print with the logic like
sed -n result,(result+10)p file
probably going to have a few issued if it pattern is in multiple lines.
Any help is appreciated