Appendix A. Regular Expressions


A. Regular Expressions

IN THIS APPENDIX

Characters

968

Delimiters

968

Simple Strings

968

Special Characters

968

Rules

971

Bracketing Expressions

972

The Replacement String

972

Extended Regular Expressions

973


A regular expression defines a set of one or more strings of characters. A simple string of characters is a regular expression that defines one string of characters: itself. A more complex regular expression uses letters, numbers, and special characters to define many different strings of characters. A regular expression is said to match any string it defines.

This appendix describes the regular expressions used by ed, vim, emacs, grep, gawk, sed, and other utilities. The regular expressions used in shell ambiguous file references are different and are described in "Filename Generation/Pathname Expansion" on page 221.




A Practical Guide to Red Hat Linux
A Practical Guide to Red HatВ® LinuxВ®: Fedoraв„ў Core and Red Hat Enterprise Linux (3rd Edition)
ISBN: 0132280272
EAN: 2147483647
Year: 2006
Pages: 383

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net