O'Reilly logo

A Practical Guide to Red Hat® Linux® 8 by Mark G. Sobell

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Appendix Summary

A regular expression defines a set of one or more strings of characters. A regular expression is said to match any string it defines.

Special Characters

. Matches any single character
* Matches zero or more occurrences of a match of the preceding character
^ Forces a match to the beginning of a line
$ A match to the end of a line
\ Used to quote special characters
\< Forces a match to the beginning of a word
\> Forces a match to the end of a word

Character Classes and Bracketed Regular Expressions

[xyz] Defines a character class that matches x, y, or z
[^ xyz] Defines a character class that matches any character except x, y, or z
[x–z] Defines a character class that matches any character x through z inclusive
\( xyz\) Matches ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required