Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What is the syntax of "grep" command?

Answer Posted / kaustubh

grep command is a utility which helps in searching pattern
from the given file.

example

grep "pattern" /home/username/somefile.txt

it ll search all lines in the file somefile.txt and will
print the line which contains pattern.

there are many options as
-v = invert
-i = ignorecase
-c = count
-l = filename
-r = recursive

Is This Answer Correct ?    7 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Suppose you execute a command using exec, what will be the status of your current process in the shell?

1078


How do I run a shell script on a mac?

1126


What is the difference between grep and egrep?

1143


How to check if a directory exists?

1199


How important is shell scripting?

1049


What are the various stages of a linux process it passes through?

1186


What language is bash?

926


What is the command to find out today's date?

1141


What lives in a shell?

963


What is the best scripting language?

1033


What are the two files of crontab command?

1237


What is a shell made of?

962


I have 2 files and I want to print the records which are common to both.

1167


What is sh in shell script?

1028


How do I run a .sh file?

1022