how to grep a word and following 10 lines in a file code example
Example 1: grep show lines above and below
grep -C 3 foo README.txt
Example 2: grep specific line
sed '3,10!d' your.file # capture line 3 to 10
#same number for single line
grep -C 3 foo README.txt
sed '3,10!d' your.file # capture line 3 to 10
#same number for single line