grep cheat sheet
------------------
-i : ignore case
-w : Match the exact word
-A n : displays n lines after the match
-B n : displays n lines before the match
-C n : displays n lines on both sides of the match
-v : inverting the match
-e : for including multiple matches ( extending the match)
-c : counting the number of match
-l : displays only the file name of the match
-o : displays only the matched string
-b : displays the position of the match in the file
-n : line number will be displayed along with the match
Monday, April 13, 2009
Subscribe to:
Post Comments (Atom)
1 comment:
one more handy switch
-s - supress errors
Post a Comment