UNIX Guide, for beginners and Mac OS X users
You are here: SillyDog701 > UNIX Guide >SillyDog701 > UNIX Guide > (index) supportSupport - ask in our friendly forums.

Using regular expressions with the grep command

The following characters can be used to create regular expressions for searching on patterns with grep.

Always quote the regular expression. This prevents the shell from interpreting the special characters before it is passed to the grep command.

c       any non-special character represents itself
\c     turns off the meaning of any special character
^       beginning of a line
$	end of a line
.       matches any single character except a newline
[...]   matches any of the enclosed characters
[^...]  matches any character that is not enclosed
[n-n]   matches any character in this range
*       matches any number of the preceding character

[Home]UNIX Guide home | [Search]search | index
Page URL: http://sillydog.org/unix/
[SillyDog701] [Netscape] [MozInfo701] [MacCentre701] [UNIX Guide] [AntTunes701][Forums] [Search] [Change Log] [Feedback] [About Us] [Sitemap]
This UNIX Guide maintained by SillyDog701, portion of this Guide is based on UNIXhelp. UNIXhelp is copyright University of Edinburgh. This page was last modified on 14 March, 2006
Netscape NOW!Made on a Mac
support MozInfo701 and SillyDog701