Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
grep shell script
Name: mehul Date: August 28, 2003 at 14:38:19 Pacific OS: sun CPU/Ram: sun
Comment:
Hello, I have a little trouble with grep...what i have is a file with many lines and any of the line may contain a word "error" , i want to grep this word "error" and print 5 lines above and 5 line below including the line in which "error" is present....
i can grep for the word error and print line which contains only error but how do i print 5 lines above and 5 line below of the line were "error" is found
Summary: Hi, I'm trying to write one shell script which will get the first entry form an ascii file whose entries looks like : 121212 xxxxxx zzzzz The criterion of getting the entry is : 1. Grep for xxxxx i...
Summary: I'm sorry I forgot to mention that this is ksh. I only use ksh for shell scripting but the grep -w part will work at the command line also. ...
Summary: Hi all, I have a problem about developing shell script to extract words with regular expression. For example, I have one text file that contain sth below.... This is a pen.I have a car.My name...