fgrep,grep and egrep
Dave Howorth
dhoworth at mrc-lmb.cam.ac.uk
Wed Jun 9 16:06:32 UTC 2010
Kaushal Shriyan wrote:
> can someone explain me about the usage of grep , fgrep and egrep
> with examples.
> In what contexts i should use which.
$ cat /bin/egrep
#!/bin/sh
exec /bin/grep -E ${1+"$@"}
$ cat /bin/fgrep
#!/bin/sh
exec /bin/grep -F ${1+"$@"}
The man page tells you what the -E and -F options do.
Basically, use whichever you find most natural.
Cheers, Dave
More information about the ubuntu-users
mailing list