Hi All,
please help me to display 5 continious lines from a particular text.
my file is as below.
file1.txt
------
Good
1
2
3
4
5
luck
1
2
3
I want to diplay 5 lines from the word Good.
I tried the below command
grep -A5 "Good" file1.txt
I got the below error message
grep: illegal option -- A
grep: illegal option -- 5
usage: grep [-E|-F] [-c|-l|-q] [-bhinsvx] -e pattern_list...
[-f pattern_file...] [file...]
usage: grep [-E|-F] [-c|-l|-q] [-bhinsvx] [-e pattern_list...]
-f pattern_file... [file...]
usage: grep [-E|-F] [-c|-l|-q] [-bhinsvx] pattern [file...]
please help me to over come this issue. Thanks!